static void musb_async_cancel_device(MUSBState *s, USBDevice *dev)

{

    int ep, dir;



    for (ep = 0; ep < 16; ep++) {

        for (dir = 0; dir < 2; dir++) {

            if (s->ep[ep].packey[dir].p.owner == NULL ||

                s->ep[ep].packey[dir].p.owner->dev != dev) {

                continue;

            }

            usb_cancel_packet(&s->ep[ep].packey[dir].p);

            /* status updates needed here? */

        }

    }

}

static void musb_async_cancel_device(MUSBState *s, USBDevice *dev)

{

    int ep, dir;



    for (ep = 0; ep < 16; ep++) {

        for (dir = 0; dir < 2; dir++) {

            if (s->ep[ep].packey[dir].p.owner == NULL ||

                s->ep[ep].packey[dir].p.owner->dev != dev) {

                continue;

            }

            usb_cancel_packet(&s->ep[ep].packey[dir].p);

            

        }

    }

}

            if (s->ep[ep].packey[dir].p.owner == NULL ||                 s->ep[ep].packey[dir].p.owner->dev != dev) {
static void FUNC_0(MUSBState *VAR_0, USBDevice *VAR_1)

{

    int VAR_2, VAR_3;



    for (VAR_2 = 0; VAR_2 < 16; VAR_2++) {

        for (VAR_3 = 0; VAR_3 < 2; VAR_3++) {

            if (VAR_0->VAR_2[VAR_2].packey[VAR_3].p.owner == NULL ||

                VAR_0->VAR_2[VAR_2].packey[VAR_3].p.owner->VAR_1 != VAR_1) {

                continue;

            }

            usb_cancel_packet(&VAR_0->VAR_2[VAR_2].packey[VAR_3].p);

            

        }

    }

}

static void FUNC_0(MUSBState *VAR_0, USBDevice *VAR_1)
{ int VAR_2, VAR_3; for (VAR_2 = 0; VAR_2 < 16; VAR_2++) { for (VAR_3 = 0; VAR_3 < 2; VAR_3++) { if (VAR_0->VAR_2[VAR_2].packey[VAR_3].p.owner == NULL ||
VAR_0->VAR_2[VAR_2].packey[VAR_3].p.owner->VAR_1 != VAR_1) { continue; } usb_cancel_packet(&VAR_0->VAR_2[VAR_2].packey[VAR_3].p); } } }