OSDN Git Service

xhci: Force Maximum Packet size for Full-speed bulk devices to valid range.
authorMathias Nyman <mathias.nyman@linux.intel.com>
Mon, 10 Feb 2020 13:45:50 +0000 (15:45 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 10 Feb 2020 14:56:20 +0000 (06:56 -0800)
commitf148b9f402ef002b57bcff3964d45abc8ffb6c3f
treee44fb0027d8998f12fc1e1d2c44f2cf10a35a067
parentbb6d3fb354c5ee8d6bde2d576eb7220ea09862b9
xhci: Force Maximum Packet size for Full-speed bulk devices to valid range.

A Full-speed bulk USB audio device (DJ-Tech CTRL) with a invalid Maximum
Packet Size of 4 causes a xHC "Parameter Error" at enumeration.

This is because valid Maximum packet sizes for Full-speed bulk endpoints
are 8, 16, 32 and 64 bytes. Hosts are not required to support other values
than these. See usb 2 specs section 5.8.3 for details.

The device starts working after forcing the maximum packet size to 8.
This is most likely the case with other devices as well, so force the
maximum packet size to a valid range.

Cc: stable@vger.kernel.org
Reported-by: Rene D Obermueller <cmdrrdo@gmail.com>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Link: https://lore.kernel.org/r/20200210134553.9144-2-mathias.nyman@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/xhci-mem.c