ChangeSet 1.2181.4.19, 2005/03/17 17:57:07-08:00, [EMAIL PROTECTED]
[PATCH] usb-midi: fix arguments to usb_maxpacket()
The usb-midi driver uses an incorrect value for the is_out argument to
usb_maxpacket(), triggering a WARN_ON. This patch fixes the mistake.
Signed-off-by: Alan Stern <[EMAIL PROTECTED]>
Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>
usb-midi.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff -Nru a/drivers/usb/class/usb-midi.c b/drivers/usb/class/usb-midi.c
--- a/drivers/usb/class/usb-midi.c 2005-03-30 15:08:09 -08:00
+++ b/drivers/usb/class/usb-midi.c 2005-03-30 15:08:09 -08:00
@@ -992,7 +992,7 @@
endPoint &= 0x0f; /* Silently force endPoint to lie in range 0 to 15. */
pipe = usb_rcvbulkpipe( d, endPoint );
- bufSize = usb_maxpacket( d, pipe, usb_pipein(pipe) );
+ bufSize = usb_maxpacket( d, pipe, 0 );
/* usb_pipein() = ! usb_pipeout() = true for an in Endpoint */
ep = (struct midi_in_endpoint *)kmalloc(sizeof(struct
midi_in_endpoint), GFP_KERNEL);
@@ -1063,7 +1063,7 @@
endPoint &= 0x0f;
pipe = usb_sndbulkpipe( d, endPoint );
- bufSize = usb_maxpacket( d, pipe, usb_pipeout(pipe) );
+ bufSize = usb_maxpacket( d, pipe, 1 );
ep = (struct midi_out_endpoint *)kmalloc(sizeof(struct
midi_out_endpoint), GFP_KERNEL);
if ( !ep ) {
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html