Lines Matching refs:uport

533 static XHCIPort *xhci_lookup_port(XHCIState *xhci, struct USBPort *uport)  in xhci_lookup_port()  argument
537 if (!uport->dev) { in xhci_lookup_port()
540 switch (uport->dev->speed) { in xhci_lookup_port()
544 index = uport->index + xhci->numports_3; in xhci_lookup_port()
547 index = uport->index; in xhci_lookup_port()
1363 if (!xhci->slots[slotid-1].uport || in xhci_reset_ep()
1364 !xhci->slots[slotid-1].uport->dev || in xhci_reset_ep()
1365 !xhci->slots[slotid-1].uport->dev->attached) { in xhci_reset_ep()
1862 return (xhci->slots[slotid - 1].uport && in xhci_slot_ok()
1863 xhci->slots[slotid - 1].uport->dev && in xhci_slot_ok()
1864 xhci->slots[slotid - 1].uport->dev->attached); in xhci_slot_ok()
2031 xhci->slots[slotid-1].uport = NULL; in xhci_enable_slot()
2052 xhci->slots[slotid-1].uport = NULL; in xhci_disable_slot()
2059 USBPort *uport; in xhci_lookup_uport() local
2067 port = xhci->ports[port-1].uport->index+1; in xhci_lookup_uport()
2077 QTAILQ_FOREACH(uport, &xhci->bus.used, next) { in xhci_lookup_uport()
2078 if (strcmp(uport->path, path) == 0) { in xhci_lookup_uport()
2079 return uport; in xhci_lookup_uport()
2089 USBPort *uport; in xhci_address_slot() local
2126 uport = xhci_lookup_uport(xhci, slot_ctx); in xhci_address_slot()
2127 if (uport == NULL) { in xhci_address_slot()
2131 trace_usb_xhci_slot_address(slotid, uport->path); in xhci_address_slot()
2133 dev = uport->dev; in xhci_address_slot()
2135 DPRINTF("xhci: port %s not connected\n", uport->path); in xhci_address_slot()
2143 if (xhci->slots[i].uport == uport) { in xhci_address_slot()
2145 uport->path, i+1); in xhci_address_slot()
2151 slot->uport = uport; in xhci_address_slot()
2405 static void xhci_detach_slot(XHCIState *xhci, USBPort *uport) in xhci_detach_slot() argument
2410 if (xhci->slots[slot].uport == uport) { in xhci_detach_slot()
2423 xhci->slots[slot].uport = NULL; in xhci_detach_slot()
2600 if (!port->uport->dev || !port->uport->dev->attached) { in xhci_port_have_device()
2603 if (!((1 << port->uport->dev->speed) & port->speedmask)) { in xhci_port_have_device()
2633 switch (port->uport->dev->speed) { in xhci_port_update()
2666 usb_device_reset(port->uport->dev); in xhci_port_reset()
2668 switch (port->uport->dev->speed) { in xhci_port_reset()
3251 static void xhci_child_detach(USBPort *uport, USBDevice *child) in xhci_child_detach() argument
3281 USBPort *uport; in xhci_epid_to_usbep() local
3287 uport = epctx->xhci->slots[epctx->slotid - 1].uport; in xhci_epid_to_usbep()
3288 if (!uport || !uport->dev) { in xhci_epid_to_usbep()
3292 return usb_ep_get(uport->dev, token, epctx->epid >> 1); in xhci_epid_to_usbep()
3338 port->uport = &xhci->uports[i]; in usb_xhci_init()
3350 port->uport = &xhci->uports[i]; in usb_xhci_init()
3467 slot->uport = xhci_lookup_uport(xhci, slot_ctx); in usb_xhci_post_load()
3468 if (!slot->uport) { in usb_xhci_post_load()
3474 assert(slot->uport && slot->uport->dev); in usb_xhci_post_load()