Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fd848319 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull HID fixes from Jiri Kosina:
 - fix for hidraw reference counting regression, by Manoj Chourasia
 - fix for minor number allocation for uhid, by David Herrmann
 - other small unsorted fixes / device ID additions

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
  HID: wiimote: fix FF deadlock
  HID: add Holtek USB ID 04d9:a081 SHARKOON DarkGlider
  HID: hidraw: close underlying device at removal of last reader
  HID: roccat: Fix "cannot create duplicate filename" problems
  HID: uhid: allocate static minor
parents 4f97c9b2 f50f9aab
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -241,6 +241,7 @@ config HID_HOLTEK
	  - Sharkoon Drakonia / Perixx MX-2000 gaming mice
	  - Sharkoon Drakonia / Perixx MX-2000 gaming mice
	  - Tracer Sniper TRM-503 / NOVA Gaming Slider X200 /
	  - Tracer Sniper TRM-503 / NOVA Gaming Slider X200 /
	    Zalman ZM-GM1
	    Zalman ZM-GM1
	  - SHARKOON DarkGlider Gaming mouse


config HOLTEK_FF
config HOLTEK_FF
	bool "Holtek On Line Grip force feedback support"
	bool "Holtek On Line Grip force feedback support"
+1 −0
Original line number Original line Diff line number Diff line
@@ -1715,6 +1715,7 @@ static const struct hid_device_id hid_have_special_driver[] = {
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT, USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HUION, USB_DEVICE_ID_HUION_580) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HUION, USB_DEVICE_ID_HUION_580) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_JESS2, USB_DEVICE_ID_JESS2_COLOR_RUMBLE_PAD) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_JESS2, USB_DEVICE_ID_JESS2_COLOR_RUMBLE_PAD) },
	{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_ION, USB_DEVICE_ID_ICADE) },
	{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_ION, USB_DEVICE_ID_ICADE) },
+4 −0
Original line number Original line Diff line number Diff line
@@ -27,6 +27,7 @@
 * - USB ID 04d9:a067, sold as Sharkoon Drakonia and Perixx MX-2000
 * - USB ID 04d9:a067, sold as Sharkoon Drakonia and Perixx MX-2000
 * - USB ID 04d9:a04a, sold as Tracer Sniper TRM-503, NOVA Gaming Slider X200
 * - USB ID 04d9:a04a, sold as Tracer Sniper TRM-503, NOVA Gaming Slider X200
 *   and Zalman ZM-GM1
 *   and Zalman ZM-GM1
 * - USB ID 04d9:a081, sold as SHARKOON DarkGlider Gaming mouse
 */
 */


static __u8 *holtek_mouse_report_fixup(struct hid_device *hdev, __u8 *rdesc,
static __u8 *holtek_mouse_report_fixup(struct hid_device *hdev, __u8 *rdesc,
@@ -46,6 +47,7 @@ static __u8 *holtek_mouse_report_fixup(struct hid_device *hdev, __u8 *rdesc,
			}
			}
			break;
			break;
		case USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A:
		case USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A:
		case USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081:
			if (*rsize >= 113 && rdesc[106] == 0xff && rdesc[107] == 0x7f
			if (*rsize >= 113 && rdesc[106] == 0xff && rdesc[107] == 0x7f
					&& rdesc[111] == 0xff && rdesc[112] == 0x7f) {
					&& rdesc[111] == 0xff && rdesc[112] == 0x7f) {
				hid_info(hdev, "Fixing up report descriptor\n");
				hid_info(hdev, "Fixing up report descriptor\n");
@@ -63,6 +65,8 @@ static const struct hid_device_id holtek_mouse_devices[] = {
			USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
			USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
			USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
			USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A) },
	{ HID_USB_DEVICE(USB_VENDOR_ID_HOLTEK_ALT,
			USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081) },
	{ }
	{ }
};
};
MODULE_DEVICE_TABLE(hid, holtek_mouse_devices);
MODULE_DEVICE_TABLE(hid, holtek_mouse_devices);
+1 −0
Original line number Original line Diff line number Diff line
@@ -450,6 +450,7 @@
#define USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD	0xa055
#define USB_DEVICE_ID_HOLTEK_ALT_KEYBOARD	0xa055
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067	0xa067
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A067	0xa067
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A	0xa04a
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A04A	0xa04a
#define USB_DEVICE_ID_HOLTEK_ALT_MOUSE_A081	0xa081


#define USB_VENDOR_ID_IMATION		0x0718
#define USB_VENDOR_ID_IMATION		0x0718
#define USB_DEVICE_ID_DISC_STAKKA	0xd000
#define USB_DEVICE_ID_DISC_STAKKA	0xd000
+1 −1
Original line number Original line Diff line number Diff line
@@ -382,7 +382,7 @@ static ssize_t kone_sysfs_write_profilex(struct file *fp,
}
}
#define PROFILE_ATTR(number)					\
#define PROFILE_ATTR(number)					\
static struct bin_attribute bin_attr_profile##number = {	\
static struct bin_attribute bin_attr_profile##number = {	\
	.attr = { .name = "profile##number", .mode = 0660 },	\
	.attr = { .name = "profile" #number, .mode = 0660 },	\
	.size = sizeof(struct kone_profile),			\
	.size = sizeof(struct kone_profile),			\
	.read = kone_sysfs_read_profilex,			\
	.read = kone_sysfs_read_profilex,			\
	.write = kone_sysfs_write_profilex,			\
	.write = kone_sysfs_write_profilex,			\
Loading