Skip to contentSkip to conversation

Usb gadget drivers 2.4 kernel

PATCH In review John Carlson 2 participants 2 messages Jun 14, 2004 – Jun 16, 2004

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Usb gadget drivers 2.4 kernel

While developing a gadget driver for the 2.4 kernel, I discovered this error in the gadget driver. This bug has been present since the gadget driver was back ported from the 2.6 kernel.

diff -urN linux-2.4.27-pre5/drivers/usb/gadget/config.c linux-2.4.27-test/drivers/usb/gadget/config.c --- linux-2.4.27-pre5/drivers/usb/gadget/config.c

 2004-06-14 09:06:48.000000000
-0400
+++ linux-2.4.27-test/drivers/usb/gadget/config.c     
 2004-06-14 09:13:02.000000000

-0400
@@ -51,7 +51,7 @@
for (; 0 != *src; src++) {
unsigned len =
(*src)->bLength;

- if (len > buflen);
+ if (len > buflen)

                        return -EINVAL;
                memcpy(dest, *src, len);
                buflen -= len;

John Carlson <[email protected]>

__________________________________
Do you Yahoo!?
Friends. Fun. Try the all-new Yahoo! Messenger.
http://messenger.yahoo.com/

#1 lore raw
Quoted 4 lines · John Carlson

While developing a gadget driver for the 2.4 kernel, I discovered this error in the gadget driver. This bug has been present since the gadget driver was back ported from the 2.6 kernel.

Actually, it's just that one source file (config.c), and the fix is in the gadget-2.4 tree already. I'll have to resubmit this one, it's rather annoying to anyone trying to make sure their new hardware works!

- Dave