aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core/quirks.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/core/quirks.c')
-rw-r--r--drivers/usb/core/quirks.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c
index 4314f259524..f073c5cb4e7 100644
--- a/drivers/usb/core/quirks.c
+++ b/drivers/usb/core/quirks.c
@@ -103,11 +103,21 @@ void usb_detect_quirks(struct usb_device *udev)
103 dev_dbg(&udev->dev, "USB quirks for this device: %x\n", 103 dev_dbg(&udev->dev, "USB quirks for this device: %x\n",
104 udev->quirks); 104 udev->quirks);
105 105
106#ifdef CONFIG_USB_SUSPEND
107
106 /* By default, disable autosuspend for all devices. The hub driver 108 /* By default, disable autosuspend for all devices. The hub driver
107 * will enable it for hubs. 109 * will enable it for hubs.
108 */ 110 */
109 usb_disable_autosuspend(udev); 111 usb_disable_autosuspend(udev);
110 112
113 /* Autosuspend can also be disabled if the initial autosuspend_delay
114 * is negative.
115 */
116 if (udev->autosuspend_delay < 0)
117 usb_autoresume_device(udev);
118
119#endif
120
111 /* For the present, all devices default to USB-PERSIST enabled */ 121 /* For the present, all devices default to USB-PERSIST enabled */
112#if 0 /* was: #ifdef CONFIG_PM */ 122#if 0 /* was: #ifdef CONFIG_PM */
113 /* Hubs are automatically enabled for USB-PERSIST */ 123 /* Hubs are automatically enabled for USB-PERSIST */