linux-uconsole/drivers/usb/core
Alan Stern c753113ae7 USB: Skip endpoints with 0 maxpacket length
[ Upstream commit d482c7bb05 ]

Endpoints with a maxpacket length of 0 are probably useless.  They
can't transfer any data, and it's not at all unlikely that an HCD will
crash or hang when trying to handle an URB for such an endpoint.

Currently the USB core does not check for endpoints having a maxpacket
value of 0.  This patch adds a check, printing a warning and skipping
over any endpoints it catches.

Now, the USB spec does not rule out endpoints having maxpacket = 0.
But since they wouldn't have any practical use, there doesn't seem to
be any good reason for us to accept them.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>

Link: https://lore.kernel.org/r/Pine.LNX.4.44L0.1910281050420.1485-100000@iolanthe.rowland.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-11-12 19:21:08 +01:00
..
buffer.c
config.c USB: Skip endpoints with 0 maxpacket length 2019-11-12 19:21:08 +01:00
devices.c
devio.c usb: usbfs: fix double-free of usb memory upon submiturb error 2019-08-16 10:12:38 +02:00
driver.c USB: core: Fix bug caused by duplicate interface PM usage counter 2019-05-08 07:21:44 +02:00
endpoint.c
file.c USB: core: Fix races in character device registration and deregistraion 2019-08-25 10:47:59 +02:00
generic.c
hcd-pci.c usb: hcd: use managed device resources 2019-09-06 10:22:15 +02:00
hcd.c usb: core: Add PM runtime calls to usb_hcd_platform_shutdown 2019-05-31 06:46:30 -07:00
hub.c usb: handle warm-reset port requests on hub resume 2019-11-06 13:05:32 +01:00
hub.h
Kconfig
ledtrig-usbport.c USB: leds: fix regression in usbport led trigger 2019-01-31 08:14:34 +01:00
Makefile
message.c USB: CDC: fix sanity checks in CDC union parser 2019-08-25 10:48:00 +02:00
notify.c
of.c
otg_whitelist.h
phy.c
phy.h
port.c
quirks.c USB: Fix chipmunk-like voice when using Logitech C270 for recording audio. 2019-06-19 08:18:05 +02:00
sysfs.c USB: Add new USB LPM helpers 2019-05-02 09:58:56 +02:00
urb.c
usb-acpi.c
usb.c USB: check usb_get_extra_descriptor for proper size 2018-12-13 09:16:15 +01:00
usb.h USB: Add new USB LPM helpers 2019-05-02 09:58:56 +02:00