summaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-asus.c
diff options
context:
space:
mode:
authorYusuke Fujimaki <usk.fujimaki@gmail.com>2016-04-03 23:15:16 +0900
committerJiri Kosina <jkosina@suse.cz>2016-04-04 09:59:21 +0200
commitb94f7d5ddf1b114e66d9bcc07d0ead080470383b (patch)
tree4082bcf40f3dfafb43c3b3295b6dc5684daf4b8c /drivers/hid/hid-asus.c
parenteeb01a57921a5e373302733d7cdf1ca87da5375a (diff)
downloadlinux-b94f7d5ddf1b114e66d9bcc07d0ead080470383b.tar.bz2
HID: asus: add support for VivoBook E200HA
Asus X205TA and E200HA built-in keyboard contain wrong logical maximum value in report descriptor. This patch correct wrong logical maximum in report descriptor. Signed-off-by: Yusuke Fujimaki <usk.fujimaki@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-asus.c')
-rw-r--r--drivers/hid/hid-asus.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/hid/hid-asus.c b/drivers/hid/hid-asus.c
index 1734e11298ed..7a811ec4f2e1 100644
--- a/drivers/hid/hid-asus.c
+++ b/drivers/hid/hid-asus.c
@@ -1,7 +1,11 @@
/*
- * HID driver for Asus X205TA built-in keyboard.
+ * HID driver for Asus notebook built-in keyboard.
* Fixes small logical maximum to match usage maximum.
*
+ * Currently supported devices are:
+ * EeeBook X205TA
+ * VivoBook E200HA
+ *
* Copyright (c) 2016 Yusuke Fujimaki <usk.fujimaki@gmail.com>
*
* This module based on hid-ortek by
@@ -25,15 +29,15 @@
static __u8 *asus_report_fixup(struct hid_device *hdev, __u8 *rdesc,
unsigned int *rsize)
{
- if (*rsize >= 180 && rdesc[54] == 0x25 && rdesc[55] == 0x65) {
- hid_info(hdev, "Fixing up Asus X205TA report descriptor\n");
+ if (*rsize >= 56 && rdesc[54] == 0x25 && rdesc[55] == 0x65) {
+ hid_info(hdev, "Fixing up Asus notebook report descriptor\n");
rdesc[55] = 0xdd;
}
return rdesc;
}
static const struct hid_device_id asus_devices[] = {
- { HID_I2C_DEVICE(USB_VENDOR_ID_ASUSTEK, USB_DEVICE_ID_ASUSTEK_X205TA_KEYBOARD) },
+ { HID_I2C_DEVICE(USB_VENDOR_ID_ASUSTEK, USB_DEVICE_ID_ASUSTEK_NOTEBOOK_KEYBOARD) },
{ }
};
MODULE_DEVICE_TABLE(hid, asus_devices);