aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/usb/core/hub.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 97deb8e6b594..003cb6b1a6bf 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -1728,8 +1728,12 @@ static int hub_probe(struct usb_interface *intf, const struct usb_device_id *id)
1728 * - Change autosuspend delay of hub can avoid unnecessary auto 1728 * - Change autosuspend delay of hub can avoid unnecessary auto
1729 * suspend timer for hub, also may decrease power consumption 1729 * suspend timer for hub, also may decrease power consumption
1730 * of USB bus. 1730 * of USB bus.
1731 *
1732 * - If user has indicated to prevent autosuspend by passing
1733 * usbcore.autosuspend = -1 then keep autosuspend disabled.
1731 */ 1734 */
1732 pm_runtime_set_autosuspend_delay(&hdev->dev, 0); 1735 if (hdev->dev.power.autosuspend_delay >= 0)
1736 pm_runtime_set_autosuspend_delay(&hdev->dev, 0);
1733 1737
1734 /* 1738 /*
1735 * Hubs have proper suspend/resume support, except for root hubs 1739 * Hubs have proper suspend/resume support, except for root hubs