Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e97aab21 authored by Hemant Kumar's avatar Hemant Kumar
Browse files

usb: core: Drive resume for 20ms for devices behind external hub



skip_extended_resume_delay module parameter is completely skipping
delay required to drive bus resume for devices behind the external
hub(s). This is causing resume failure for the device. Fix the
issue by driving resume for 20ms.

Change-Id: I13ba8094c7eab119f1d41ebc9e15c9aa91096201
Signed-off-by: default avatarHemant Kumar <hemantk@codeaurora.org>
parent 28f110a2
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -3486,7 +3486,8 @@ int usb_port_resume(struct usb_device *udev, pm_message_t msg)
		/* drive resume for USB_RESUME_TIMEOUT msec */
		dev_dbg(&udev->dev, "usb %sresume\n",
				(PMSG_IS_AUTO(msg) ? "auto-" : ""));
		if (!skip_extended_resume_delay)
		if (!skip_extended_resume_delay ||
				udev->parent != udev->bus->root_hub)
			usleep_range(USB_RESUME_TIMEOUT * 1000,
					(USB_RESUME_TIMEOUT + 1) * 1000);

+1 −1
Original line number Diff line number Diff line
@@ -305,7 +305,7 @@ void usb_put_intf(struct usb_interface *intf);
 * should cope with both LPJ calibration errors and devices not following every
 * detail of the USB Specification.
 */
#define USB_RESUME_TIMEOUT	40 /* ms */
#define USB_RESUME_TIMEOUT	20 /* ms */

/**
 * struct usb_interface_cache - long-term representation of a device interface