--- depmod-dist.c Thu Jan 4 19:18:18 2001 +++ depmod.c Thu Jan 4 19:23:04 2001 @@ -101,7 +101,7 @@ } devs[ISAPNP_CARD_DEVS]; /* logical devices */ }; -/* Extracted from 2.4.0-test10-pre3 + David Brownell usb-device_id patch 2 */ +/* Extracted from 2.4.0 */ #ifndef __u16 #define __u16 u_int16_t #endif @@ -121,6 +121,11 @@ * Init the fields you care about; zeroes are not used in comparisons. */ struct usb_device_id { + /* This bitmask is used to determine which of the following fields + * are to be used for matching. + */ + __u16 match_flags; + /* * vendor/product codes are checked, if vendor is nonzero * Range is for device revision (bcdDevice), inclusive; @@ -1075,7 +1080,7 @@ } ptmod = modules; - fprintf(usbmap, "# usb module idVendor idProduct bcdDevice_lo bcdDevice_hi" + fprintf(usbmap, "# usb module match_flags idVendor idProduct bcdDevice_lo bcdDevice_hi" " bDeviceClass bDeviceSubClass bDeviceProtocol bInterfaceClass bInterfaceSubClass" " bInterfaceProtocol driver_info\n"); for (i = 0; i < n_modules; i++, ptmod++) { @@ -1084,10 +1089,11 @@ if (!ptmod->n_usb_device) continue; for (j = 0; j < ptmod->n_usb_device; j++, usb_device++) { - fprintf(usbmap, "%-20s 0x%0*x 0x%0*x 0x%0*x 0x%0*x " + fprintf(usbmap, "%-20s 0x%0*x 0x%0*x 0x%0*x 0x%0*x 0x%0*x " "0x%0*x 0x%0*x 0x%0*x 0x%0*x 0x%0*x " "0x%0*x 0x%0*" tgt_long_fmt "x\n", shortname(ptmod->name), + 2*sizeof(usb_device->match_flags), usb_device->match_flags, 2*sizeof(usb_device->idVendor), usb_device->idVendor, 2*sizeof(usb_device->idProduct), usb_device->idProduct, 2*sizeof(usb_device->bcdDevice_lo), usb_device->bcdDevice_lo,