]> git.itanic.dy.fi Git - linux-stable/commit
usbip: fix usbip attach to find a port that matches the requested speed
authorShuah Khan <shuahkh@osg.samsung.com>
Wed, 29 Nov 2017 22:24:22 +0000 (15:24 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 10 Dec 2017 12:40:37 +0000 (13:40 +0100)
commite0264c662ca8ba118715072927af08d96fd90a36
treea206c5a7f67945b4626df8ad1d97b695f7af7e2b
parentb8e212c599082896a180a18a0c9bd529526590be
usbip: fix usbip attach to find a port that matches the requested speed

commit 1ac7c8a78be85f84b019d3d2742d1a9f07255cc5 upstream.

usbip attach fails to find a free port when the device on the first port
is a USB_SPEED_SUPER device and non-super speed device is being attached.
It keeps checking the first port and returns without a match getting stuck
in a loop.

Fix it check to find the first port with matching speed.

Reported-by: Juan Zea <juan.zea@qindel.com>
Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/usb/usbip/libsrc/vhci_driver.c