>Doh, good catch.  This had been reported previously with the scanner
>driver.  I'll apply your patch, thanks.  Want to make one up for the
>other callers of usb_register_dev()?  :)

I took a quick look at other callers (maybe need some reread by those
drivers repective authors):
- class/usblp.c => seems OK,
- image/scanner.c => not verified (should be OK according to your
above message)
- image/mdc800.c => seems OK,
- media/dabusb.c => seems OK,
- misc/brlvger.c => seems OK (not using devices indexed table),
- misc/auerswald.c => seems OK,
- misc/rio500.c => seems OK (not using devices indexed table),
- misc/usblcd.c => seems OK (not using dynamic minors),
- usb-skeleton.c  => seems to have a bad indexation when not in dynamic.
Here's a 2 lines patch ;-) The format (tab not stripped) should be good
this time...

=================================================================================
--- linux-2.5.44/drivers/usb/usb-skeleton.c   Sat Oct 19 06:01:53 2002
+++ linux-2.5.44-dyndev/drivers/usb/usb-skeleton.c      Fri Oct 25 10:38:38 2002
@@ -218,7 +218,7 @@
  */
 static inline void skel_delete (struct usb_skel *dev)
 {
-    minor_table[dev->minor] = NULL;
+    minor_table[dev->minor - USB_SKEL_MINOR_BASE] = NULL;
     if (dev->bulk_in_buffer != NULL)
          kfree (dev->bulk_in_buffer);
     if (dev->bulk_out_buffer != NULL)
@@ -544,7 +544,7 @@
          goto exit_minor;
     }
     memset (dev, 0x00, sizeof (*dev));
-    minor_table[minor] = dev;
+    minor_table[minor - USB_SKEL_MINOR_BASE] = dev;

     init_MUTEX (&dev->sem);
     dev->udev = udev;

=================================================================================

>Your mailer stripped the tabs out of your patch.  I fixed it by hand
>this time, but you might want to fix that for any future patches.

argh, I noticed it. Sorry for this embarassment. I've tried with UUencode this
time. This should be better.

Arnaud




-------------------------------------------------------
This sf.net email is sponsored by: Influence the future 
of Java(TM) technology. Join the Java Community 
Process(SM) (JCP(SM)) program now. 
http://ads.sourceforge.net/cgi-bin/redirect.pl?sunm0004en
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to