usb-storage: use first bulk endpoints, not last
authorAlan Stern <stern@rowland.harvard.edu>
Mon, 22 Jan 2007 16:58:34 +0000 (11:58 -0500)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 7 Feb 2007 23:44:40 +0000 (15:44 -0800)
commit1096f780d0b9d6bade2d42bf823e81db3e553abe
treed72bf456ec6a0d1b720839d157d5867059051775
parent629e4427aa817d5c9f11885420abf54b8f5967dc
usb-storage: use first bulk endpoints, not last

According to the Bulk-Only spec, usb-storage is supposed to use the
_first_ bulk-in and bulk-out endpoints it finds, not the _last_.  And
while we're at it, we ought to test the direction of the interrupt
endpoint as well.  This patch (as842) makes both changes.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Cc: Matthew Dharm <mdharm-usb@one-eyed-alien.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/storage/usb.c