static int uhci_broadcast_packet(UHCIState *s, USBPacket *p)

{

    int i, ret;



    DPRINTF("uhci: packet enter. pid %s addr 0x%02x ep %d len %d\n",

           pid2str(p->pid), p->devaddr, p->devep, p->len);

    if (p->pid == USB_TOKEN_OUT || p->pid == USB_TOKEN_SETUP)

        dump_data(p->data, p->len);



    ret = USB_RET_NODEV;

    for (i = 0; i < NB_PORTS && ret == USB_RET_NODEV; i++) {

        UHCIPort *port = &s->ports[i];

        USBDevice *dev = port->port.dev;



        if (dev && (port->ctrl & UHCI_PORT_EN))

            ret = usb_handle_packet(dev, p);

    }



    DPRINTF("uhci: packet exit. ret %d len %d\n", ret, p->len);

    if (p->pid == USB_TOKEN_IN && ret > 0)

        dump_data(p->data, ret);



    return ret;

}

static int uhci_broadcast_packet(UHCIState *s, USBPacket *p)

{

    int i, ret;



    DPRINTF("uhci: packet enter. pid %s addr 0x%02x ep %d len %d\n",

           pid2str(p->pid), p->devaddr, p->devep, p->len);

    if (p->pid == USB_TOKEN_OUT || p->pid == USB_TOKEN_SETUP)

        dump_data(p->data, p->len);



    ret = USB_RET_NODEV;

    for (i = 0; i < NB_PORTS && ret == USB_RET_NODEV; i++) {

        UHCIPort *port = &s->ports[i];

        USBDevice *dev = port->port.dev;



        if (dev && (port->ctrl & UHCI_PORT_EN))

            ret = usb_handle_packet(dev, p);

    }



    DPRINTF("uhci: packet exit. ret %d len %d\n", ret, p->len);

    if (p->pid == USB_TOKEN_IN && ret > 0)

        dump_data(p->data, ret);



    return ret;

}

    DPRINTF("uhci: packet enter. pid %s addr 0x%02x ep %d len %d\n",            pid2str(p->pid), p->devaddr, p->devep, p->len);         dump_data(p->data, p->len);     DPRINTF("uhci: packet exit. ret %d len %d\n", ret, p->len);         dump_data(p->data, ret);
static int FUNC_0(UHCIState *VAR_0, USBPacket *VAR_1)

{

    int VAR_2, VAR_3;



    DPRINTF("uhci: packet enter. pid %VAR_0 addr 0x%02x ep %d len %d\n",

           pid2str(VAR_1->pid), VAR_1->devaddr, VAR_1->devep, VAR_1->len);

    if (VAR_1->pid == USB_TOKEN_OUT || VAR_1->pid == USB_TOKEN_SETUP)

        dump_data(VAR_1->data, VAR_1->len);



    VAR_3 = USB_RET_NODEV;

    for (VAR_2 = 0; VAR_2 < NB_PORTS && VAR_3 == USB_RET_NODEV; VAR_2++) {

        UHCIPort *port = &VAR_0->ports[VAR_2];

        USBDevice *dev = port->port.dev;



        if (dev && (port->ctrl & UHCI_PORT_EN))

            VAR_3 = usb_handle_packet(dev, VAR_1);

    }



    DPRINTF("uhci: packet exit. VAR_3 %d len %d\n", VAR_3, VAR_1->len);

    if (VAR_1->pid == USB_TOKEN_IN && VAR_3 > 0)

        dump_data(VAR_1->data, VAR_3);



    return VAR_3;

}

static int FUNC_0(UHCIState *VAR_0, USBPacket *VAR_1)
{ int VAR_2, VAR_3; DPRINTF("uhci: packet enter. pid %VAR_0 addr 0x%02x ep %d len %d\n",
pid2str(VAR_1->pid), VAR_1->devaddr, VAR_1->devep, VAR_1->len); if (VAR_1->pid == USB_TOKEN_OUT || VAR_1->pid == USB_TOKEN_SETUP)
dump_data(VAR_1->data, VAR_1->len); VAR_3 = USB_RET_NODEV; for (VAR_2 = 0; VAR_2 < NB_PORTS && VAR_3 == USB_RET_NODEV; VAR_2++) { UHCIPort *port = &VAR_0->ports[VAR_2]; USBDevice *dev = port->port.dev; if (dev && (port->ctrl & UHCI_PORT_EN))
VAR_3 = usb_handle_packet(dev, VAR_1); } DPRINTF("uhci: packet exit. VAR_3 %d len %d\n", VAR_3, VAR_1->len); if (VAR_1->pid == USB_TOKEN_IN && VAR_3 > 0)
dump_data(VAR_1->data, VAR_3); return VAR_3; }