Lines Matching refs:rhdev
2209 int hcd_bus_suspend(struct usb_device *rhdev, pm_message_t msg) in hcd_bus_suspend() argument
2211 struct usb_hcd *hcd = container_of(rhdev->bus, struct usb_hcd, self); in hcd_bus_suspend()
2215 dev_dbg(&rhdev->dev, "bus %ssuspend, wakeup %d\n", in hcd_bus_suspend()
2217 rhdev->do_remote_wakeup); in hcd_bus_suspend()
2219 dev_dbg(&rhdev->dev, "skipped %s of dead bus\n", "suspend"); in hcd_bus_suspend()
2231 usb_set_device_state(rhdev, USB_STATE_SUSPENDED); in hcd_bus_suspend()
2235 if (rhdev->do_remote_wakeup) { in hcd_bus_suspend()
2240 dev_dbg(&rhdev->dev, "suspend raced with wakeup event\n"); in hcd_bus_suspend()
2241 hcd_bus_resume(rhdev, PMSG_AUTO_RESUME); in hcd_bus_suspend()
2252 dev_dbg(&rhdev->dev, "bus %s fail, err %d\n", in hcd_bus_suspend()
2258 int hcd_bus_resume(struct usb_device *rhdev, pm_message_t msg) in hcd_bus_resume() argument
2260 struct usb_hcd *hcd = container_of(rhdev->bus, struct usb_hcd, self); in hcd_bus_resume()
2264 dev_dbg(&rhdev->dev, "usb %sresume\n", in hcd_bus_resume()
2267 dev_dbg(&rhdev->dev, "skipped %s of dead bus\n", "resume"); in hcd_bus_resume()
2284 usb_set_device_state(rhdev, rhdev->actconfig in hcd_bus_resume()
2298 usb_hub_for_each_child(rhdev, port1, udev) { in hcd_bus_resume()
2307 dev_dbg(&rhdev->dev, "bus %s fail, err %d\n", in hcd_bus_resume()
2660 struct usb_device *rhdev; in usb_put_invalidate_rhdev() local
2663 rhdev = hcd->self.root_hub; in usb_put_invalidate_rhdev()
2666 usb_put_dev(rhdev); in usb_put_invalidate_rhdev()
2683 struct usb_device *rhdev; in usb_add_hcd() local
2760 rhdev = usb_alloc_dev(NULL, &hcd->self, 0); in usb_add_hcd()
2761 if (rhdev == NULL) { in usb_add_hcd()
2767 hcd->self.root_hub = rhdev; in usb_add_hcd()
2772 rhdev->speed = USB_SPEED_FULL; in usb_add_hcd()
2775 rhdev->speed = USB_SPEED_HIGH; in usb_add_hcd()
2778 rhdev->speed = USB_SPEED_WIRELESS; in usb_add_hcd()
2782 rhdev->speed = USB_SPEED_SUPER; in usb_add_hcd()
2793 device_set_wakeup_capable(&rhdev->dev, 1); in usb_add_hcd()
2844 retval = sysfs_create_group(&rhdev->dev.kobj, &usb_bus_attr_group); in usb_add_hcd()
2867 usb_disconnect(&rhdev); /* Sets rhdev to NULL */ in usb_add_hcd()
2915 struct usb_device *rhdev = hcd->self.root_hub; in usb_remove_hcd() local
2919 usb_get_dev(rhdev); in usb_remove_hcd()
2920 sysfs_remove_group(&rhdev->dev.kobj, &usb_bus_attr_group); in usb_remove_hcd()
2936 usb_disconnect(&rhdev); /* Sets rhdev to NULL */ in usb_remove_hcd()