void usb_packet_set_state(USBPacket *p, USBPacketState state)

{

    static const char *name[] = {

        [USB_PACKET_UNDEFINED] = "undef",

        [USB_PACKET_SETUP]     = "setup",

        [USB_PACKET_QUEUED]    = "queued",

        [USB_PACKET_ASYNC]     = "async",

        [USB_PACKET_COMPLETE]  = "complete",

        [USB_PACKET_CANCELED]  = "canceled",

    };

    USBDevice *dev = p->ep->dev;

    USBBus *bus = usb_bus_from_device(dev);



    trace_usb_packet_state_change(bus->busnr, dev->port->path, p->ep->nr,

                                  p, name[p->state], name[state]);

    p->state = state;

}

void usb_packet_set_state(USBPacket *p, USBPacketState state)

{

    static const char *name[] = {

        [USB_PACKET_UNDEFINED] = "undef",

        [USB_PACKET_SETUP]     = "setup",

        [USB_PACKET_QUEUED]    = "queued",

        [USB_PACKET_ASYNC]     = "async",

        [USB_PACKET_COMPLETE]  = "complete",

        [USB_PACKET_CANCELED]  = "canceled",

    };

    USBDevice *dev = p->ep->dev;

    USBBus *bus = usb_bus_from_device(dev);



    trace_usb_packet_state_change(bus->busnr, dev->port->path, p->ep->nr,

                                  p, name[p->state], name[state]);

    p->state = state;

}

void usb_packet_set_state(USBPacket *p, USBPacketState state)     trace_usb_packet_state_change(bus->busnr, dev->port->path, p->ep->nr,                                   p, name[p->state], name[state]);
void FUNC_0(USBPacket *VAR_0, USBPacketState VAR_1)

{

    static const char *VAR_2[] = {

        [USB_PACKET_UNDEFINED] = "undef",

        [USB_PACKET_SETUP]     = "setup",

        [USB_PACKET_QUEUED]    = "queued",

        [USB_PACKET_ASYNC]     = "async",

        [USB_PACKET_COMPLETE]  = "complete",

        [USB_PACKET_CANCELED]  = "canceled",

    };

    USBDevice *dev = VAR_0->ep->dev;

    USBBus *bus = usb_bus_from_device(dev);



    trace_usb_packet_state_change(bus->busnr, dev->port->path, VAR_0->ep->nr,

                                  VAR_0, VAR_2[VAR_0->VAR_1], VAR_2[VAR_1]);

    VAR_0->VAR_1 = VAR_1;

}

void FUNC_0(USBPacket *VAR_0, USBPacketState VAR_1)
{ static const char *VAR_2[] = { [USB_PACKET_UNDEFINED] = "undef",
[USB_PACKET_SETUP]     = "setup",
[USB_PACKET_QUEUED]    = "queued",
[USB_PACKET_ASYNC]     = "async",
[USB_PACKET_COMPLETE]  = "complete",
[USB_PACKET_CANCELED]  = "canceled",
}; USBDevice *dev = VAR_0->ep->dev; USBBus *bus = usb_bus_from_device(dev); trace_usb_packet_state_change(bus->busnr, dev->port->path, VAR_0->ep->nr,
VAR_0, VAR_2[VAR_0->VAR_1], VAR_2[VAR_1]); VAR_0->VAR_1 = VAR_1; }