Skip to content

Commit 3155f4f

Browse files
AlanSterngregkh
authored andcommitted
USB: hub: Revert commit bd0e6c9 ("usb: hub: try old enumeration scheme first for high speed devices")
Commit bd0e6c9 ("usb: hub: try old enumeration scheme first for high speed devices") changed the way the hub driver enumerates high-speed devices. Instead of using the "new" enumeration scheme first and switching to the "old" scheme if that doesn't work, we start with the "old" scheme. In theory this is better because the "old" scheme is slightly faster -- it involves resetting the device only once instead of twice. However, for a long time Windows used only the "new" scheme. Zeng Tao said that Windows 8 and later use the "old" scheme for high-speed devices, but apparently there are some devices that don't like it. William Bader reports that the Ricoh webcam built into his Sony Vaio laptop not only doesn't enumerate under the "old" scheme, it gets hung up so badly that it won't then enumerate under the "new" scheme! Only a cold reset will fix it. Therefore we will revert the commit and go back to trying the "new" scheme first for high-speed devices. Reported-and-tested-by: William Bader <[email protected]> Ref: https://bugzilla.kernel.org/show_bug.cgi?id=207219 Signed-off-by: Alan Stern <[email protected]> Fixes: bd0e6c9 ("usb: hub: try old enumeration scheme first for high speed devices") CC: Zeng Tao <[email protected]> CC: <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 9f952e2 commit 3155f4f

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

Documentation/admin-guide/kernel-parameters.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5187,8 +5187,7 @@
51875187

51885188
usbcore.old_scheme_first=
51895189
[USB] Start with the old device initialization
5190-
scheme, applies only to low and full-speed devices
5191-
(default 0 = off).
5190+
scheme (default 0 = off).
51925191

51935192
usbcore.usbfs_memory_mb=
51945193
[USB] Memory limit (in MB) for buffers allocated by

drivers/usb/core/hub.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2728,13 +2728,11 @@ static bool use_new_scheme(struct usb_device *udev, int retry,
27282728
{
27292729
int old_scheme_first_port =
27302730
port_dev->quirks & USB_PORT_QUIRK_OLD_SCHEME;
2731-
int quick_enumeration = (udev->speed == USB_SPEED_HIGH);
27322731

27332732
if (udev->speed >= USB_SPEED_SUPER)
27342733
return false;
27352734

2736-
return USE_NEW_SCHEME(retry, old_scheme_first_port || old_scheme_first
2737-
|| quick_enumeration);
2735+
return USE_NEW_SCHEME(retry, old_scheme_first_port || old_scheme_first);
27382736
}
27392737

27402738
/* Is a USB 3.0 port in the Inactive or Compliance Mode state?

0 commit comments

Comments
 (0)