kern/80383: [PATCH] Add quirk for uhid to ignore certain usb
devices (blacklist)
Thierry Thomas
thierry at FreeBSD.org
Sat Apr 30 09:09:41 PDT 2005
Le Mer 27 avr 05 à 7:55:31 +0200, Lonnie Mendez <lmendez19 at austin.rr.com>
écrivait :
>
> >Number: 80383
> >Category: kern
> >Synopsis: [PATCH] Add quirk for uhid to ignore certain usb devices (blacklist)
> >Description:
>
> This patch allows uhid to leave alone devices that identify themselves as hid based, but are indeed
> used via another interface. This is very simliar in concept to the hid blacklist table found in hid-core.c
> in the linux kernel.
Fine! I also need this to use the new MGE UPS devices (with nut, libusb
and the newhidups driver). I have applied the submitted patch on a
5.4-STABLE, and it's OK.
To add the MGE UPS devices, I need the attached patches.
--
Th. Thomas.
-------------- next part --------------
--- src/sys/dev/usb/usb_quirks.c.orig Sat Feb 5 16:05:51 2005
+++ src/sys/dev/usb/usb_quirks.c Sat Apr 30 09:27:35 2005
@@ -101,6 +101,13 @@
ANY, { UQ_ASSUME_CM_OVER_DATA }},
{ USB_VENDOR_SUNTAC, USB_PRODUCT_SUNTAC_AS64LX,
0x100, { UQ_ASSUME_CM_OVER_DATA }},
+ /* Devices which should be ignored by uhid */
+ { USB_VENDOR_DELORME, USB_PRODUCT_DELORME_EARTHMATE,
+ ANY, { UQ_HID_IGNORE }},
+ { USB_VENDOR_MGE, USB_PRODUCT_MGE_UPS1,
+ ANY, { UQ_HID_IGNORE }},
+ { USB_VENDOR_MGE, USB_PRODUCT_MGE_UPS2,
+ ANY, { UQ_HID_IGNORE }},
{ 0, 0, 0, { 0 } }
};
-------------- next part --------------
--- src/sys/dev/usb/usbdevs.orig Sun Apr 3 16:37:47 2005
+++ src/sys/dev/usb/usbdevs Sat Apr 30 16:00:53 2005
@@ -90,6 +90,7 @@
vendor DIAMOND2 0x045a Diamond (Supra)
vendor MICROSOFT 0x045e Microsoft
vendor PRIMAX 0x0461 Primax Electronics
+vendor MGE 0x0463 MGE UPS Systems
vendor AMP 0x0464 AMP
vendor CHERRY 0x046a Cherry Mikroschalter
vendor MEGATRENDS 0x046b American Megatrends
@@ -962,6 +963,10 @@
/* Metricom products */
product METRICOM RICOCHET_GS 0x0001 Ricochet GS
+
+/* MGE UPS Systems */
+product MGE UPS1 0x0001 MGEUPS newhidups 1
+product MGE UPS2 0xffff MGEUPS newhidups 2
/* Microsoft products */
product MICROSOFT SIDEPREC 0x0008 SideWinder Precision Pro
More information about the freebsd-usb
mailing list