Lines Matching refs:udev
26 int usb_lock_async(struct usb_device *udev, int lock) in usb_lock_async() argument
28 struct udevice *bus = udev->controller_dev; in usb_lock_async()
45 int submit_int_msg(struct usb_device *udev, unsigned long pipe, void *buffer, in submit_int_msg() argument
48 struct udevice *bus = udev->controller_dev; in submit_int_msg()
54 return ops->interrupt(bus, udev, pipe, buffer, length, interval, in submit_int_msg()
58 int submit_control_msg(struct usb_device *udev, unsigned long pipe, in submit_control_msg() argument
61 struct udevice *bus = udev->controller_dev; in submit_control_msg()
69 err = ops->control(bus, udev, pipe, buffer, length, setup); in submit_control_msg()
81 int submit_bulk_msg(struct usb_device *udev, unsigned long pipe, void *buffer, in submit_bulk_msg() argument
84 struct udevice *bus = udev->controller_dev; in submit_bulk_msg()
90 return ops->bulk(bus, udev, pipe, buffer, length); in submit_bulk_msg()
93 struct int_queue *create_int_queue(struct usb_device *udev, in create_int_queue() argument
97 struct udevice *bus = udev->controller_dev; in create_int_queue()
103 return ops->create_int_queue(bus, udev, pipe, queuesize, elementsize, in create_int_queue()
107 void *poll_int_queue(struct usb_device *udev, struct int_queue *queue) in poll_int_queue() argument
109 struct udevice *bus = udev->controller_dev; in poll_int_queue()
115 return ops->poll_int_queue(bus, udev, queue); in poll_int_queue()
118 int destroy_int_queue(struct usb_device *udev, struct int_queue *queue) in destroy_int_queue() argument
120 struct udevice *bus = udev->controller_dev; in destroy_int_queue()
126 return ops->destroy_int_queue(bus, udev, queue); in destroy_int_queue()
129 int usb_alloc_device(struct usb_device *udev) in usb_alloc_device() argument
131 struct udevice *bus = udev->controller_dev; in usb_alloc_device()
138 return ops->alloc_device(bus, udev); in usb_alloc_device()
141 int usb_reset_root_port(struct usb_device *udev) in usb_reset_root_port() argument
143 struct udevice *bus = udev->controller_dev; in usb_reset_root_port()
149 return ops->reset_root_port(bus, udev); in usb_reset_root_port()
152 int usb_update_hub_device(struct usb_device *udev) in usb_update_hub_device() argument
154 struct udevice *bus = udev->controller_dev; in usb_update_hub_device()
160 return ops->update_hub_device(bus, udev); in usb_update_hub_device()
163 int usb_get_max_xfer_size(struct usb_device *udev, size_t *size) in usb_get_max_xfer_size() argument
165 struct udevice *bus = udev->controller_dev; in usb_get_max_xfer_size()
357 struct usb_device *udev; in find_child_devnum() local
362 udev = dev_get_parent_priv(parent); in find_child_devnum()
363 if (udev->devnum == devnum) in find_child_devnum()
364 return udev; in find_child_devnum()
369 udev = find_child_devnum(dev, devnum); in find_child_devnum()
370 if (udev) in find_child_devnum()
371 return udev; in find_child_devnum()
650 ALLOC_CACHE_ALIGN_BUFFER(struct usb_device, udev, 1); in usb_scan_device()
651 struct usb_interface_descriptor *iface = &udev->config.if_desc[0].desc; in usb_scan_device()
654 memset(udev, '\0', sizeof(*udev)); in usb_scan_device()
655 udev->controller_dev = usb_get_bus(parent); in usb_scan_device()
656 priv = dev_get_uclass_priv(udev->controller_dev); in usb_scan_device()
686 udev->dev = parent; in usb_scan_device()
687 udev->speed = speed; in usb_scan_device()
688 udev->devnum = priv->next_addr + 1; in usb_scan_device()
689 udev->portnr = port; in usb_scan_device()
690 debug("Calling usb_setup_device(), portnr=%d\n", udev->portnr); in usb_scan_device()
693 ret = usb_setup_device(udev, priv->desc_before_addr, parent_udev); in usb_scan_device()
697 ret = usb_find_child(parent, &udev->descriptor, iface, &dev); in usb_scan_device()
702 ret = usb_find_and_bind_driver(parent, &udev->descriptor, in usb_scan_device()
704 dev_seq(udev->controller_dev), in usb_scan_device()
705 udev->devnum, port, &dev); in usb_scan_device()
712 plat->devnum = udev->devnum; in usb_scan_device()
713 plat->udev = udev; in usb_scan_device()
743 struct usb_device *udev; in usb_detect_change() local
756 udev = dev_get_parent_priv(dev); in usb_detect_change()
757 if (usb_get_port_status(udev, udev->portnr, &status) in usb_detect_change()
811 struct usb_device *udev = dev_get_parent_priv(dev); in usb_child_pre_probe() local
815 if (plat->udev) { in usb_child_pre_probe()
821 *udev = *(plat->udev); in usb_child_pre_probe()
823 plat->udev = NULL; in usb_child_pre_probe()
824 udev->dev = dev; in usb_child_pre_probe()
831 udev->dev = dev; in usb_child_pre_probe()
832 udev->controller_dev = usb_get_bus(dev); in usb_child_pre_probe()
833 udev->devnum = plat->devnum; in usb_child_pre_probe()
839 ret = usb_select_config(udev); in usb_child_pre_probe()