]> git.baikalelectronics.ru Git - kernel.git/commit
USB: Fix parsing of SuperSpeed Endpoint Companion descriptor.
authorSarah Sharp <sarah.a.sharp@linux.intel.com>
Mon, 27 Jul 2009 19:04:52 +0000 (12:04 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 28 Jul 2009 21:31:13 +0000 (14:31 -0700)
commit17873c7211df1c92a6b995ccd0cae97fa0a58d28
tree3bf74326b6ee6e4256e3166a909d96d3e3569394
parent3afe84fa434a0ea2fe01be1ba4dd16bb8d2e687b
USB: Fix parsing of SuperSpeed Endpoint Companion descriptor.

usb_parse_ss_endpoint_companion() was supposed to allocate a structure to
hold the SuperSpeed Endpoint Companion descriptor, and either copy the
values the device returned, or fill in default values if the device
descriptor did not include the companion descriptor.

However, the previous code would miss the last endpoint in a configuration
with no descriptors after it.  Make usb_parse_endpoint() allocate the SS
endpoint companion descriptor and fill it with default values, even if
we've run out of buffer space in this configuration descriptor.

Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/core/config.c