Skip to content

Commit f1a4914

Browse files
ablacksheepJiri Kosina
authored andcommitted
HID: add support for LEETGION Hellion Gaming Mouse
Added id, bindings and comments for Holtek USB ID 04d9:a072 LEETGION Hellion Gaming mouse to use the same corrections of the report descriptor as Holtek 04d9:a067. As the mouse exceed HID_MAX_USAGES at the same offsets in the reported descriptor. Tested on the hardware. Signed-off-by: Anders F. U. Kiær <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
1 parent 1c24113 commit f1a4914

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed

drivers/hid/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ config HID_HOLTEK
242242
- Tracer Sniper TRM-503 / NOVA Gaming Slider X200 /
243243
Zalman ZM-GM1
244244
- SHARKOON DarkGlider Gaming mouse
245+
- LEETGION Hellion Gaming Mouse
245246

246247
config HOLTEK_FF
247248
bool "Holtek On Line Grip force feedback support"

drivers/hid/hid-core.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1716,6 +1716,7 @@ static const struct hid_device_id hid_have_special_driver[] = {
17161716
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD) },
17171717
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
17181718
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
1719+
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A072) },
17191720
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081) },
17201721
{ HID_USB_DEVICE(USB_VENDOR_ID_HUION, USB_DEVICE_ID_HUION_580) },
17211722
{ HID_USB_DEVICE(USB_VENDOR_ID_JESS2, USB_DEVICE_ID_JESS2_COLOR_RUMBLE_PAD) },

drivers/hid/hid-holtek-mouse.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
* - USB ID 04d9:a04a, sold as Tracer Sniper TRM-503, NOVA Gaming Slider X200
2929
* and Zalman ZM-GM1
3030
* - USB ID 04d9:a081, sold as SHARKOON DarkGlider Gaming mouse
31+
* - USB ID 04d9:a072, sold as LEETGION Hellion Gaming Mouse
3132
*/
3233

3334
static __u8 *holtek_mouse_report_fixup(struct hid_device *hdev, __u8 *rdesc,
@@ -40,6 +41,7 @@ static __u8 *holtek_mouse_report_fixup(struct hid_device *hdev, __u8 *rdesc,
4041
* 0x2fff, so they don't exceed HID_MAX_USAGES */
4142
switch (hdev->product) {
4243
case USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067:
44+
case USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A072:
4345
if (*rsize >= 122 && rdesc[115] == 0xff && rdesc[116] == 0x7f
4446
&& rdesc[120] == 0xff && rdesc[121] == 0x7f) {
4547
hid_info(hdev, "Fixing up report descriptor\n");
@@ -65,6 +67,8 @@ static const struct hid_device_id holtek_mouse_devices[] = {
6567
USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
6668
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
6769
USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
70+
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
71+
USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A072) },
6872
{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
6973
USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081) },
7074
{ }

drivers/hid/hid-ids.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,8 +448,9 @@
448448

449449
#define USB_VENDOR_ID_HOLTEK_ALT 0x04d9
450450
#define USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD 0xa055
451-
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067 0xa067
452451
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A 0xa04a
452+
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067 0xa067
453+
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A072 0xa072
453454
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081 0xa081
454455

455456
#define USB_VENDOR_ID_IMATION 0x0718

0 commit comments

Comments
 (0)