Hans de Goede 3c785a06de HID: ite: Replace ABS_MISC 120/121 events with touchpad on/off keypresses
The usb-hid keyboard-dock for the Acer Switch 10 SW5-012 model declares
an application and hid-usage page of 0x0088 for the INPUT(4) report which
it sends. This reports contains 2 8-bit fields which are declared as
HID_MAIN_ITEM_VARIABLE.

The keyboard-touchpad combo never actually generates this report, except
when the touchpad is toggled on/off with the Fn + F7 hotkey combo. The
toggle on/off is handled inside the keyboard-dock, when the touchpad is
toggled off it simply stops sending events.

When the touchpad is toggled on/off an INPUT(4) report is generated with
the first content byte set to 120/121, before this commit the kernel
would report this as ABS_MISC 120/121 events.

Patch the descriptor to replace the HID_MAIN_ITEM_VARIABLE with
HID_MAIN_ITEM_RELATIVE (because no key-presss release events are send)
and add mappings for the 0x00880078 and 0x00880079 usages to generate
touchpad on/off key events when the touchpad is toggled on/off.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2020-10-22 13:42:34 +02:00
..
2020-10-15 14:43:29 -07:00
2020-10-15 14:43:29 -07:00
2020-10-13 13:04:41 -07:00
2020-10-15 10:01:51 -07:00
2020-10-15 10:46:16 -07:00
2020-10-14 10:32:10 -07:00
2020-10-15 14:43:29 -07:00
2020-10-12 13:26:49 -07:00
2020-10-14 15:56:58 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 10:32:10 -07:00
2020-10-14 16:09:32 -07:00
2020-10-13 12:12:44 -07:00
2020-10-15 11:07:44 -07:00
2020-10-13 12:12:44 -07:00
2020-10-14 10:32:10 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 15:56:58 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 12:08:34 -07:00
2020-09-28 12:17:36 +02:00
2020-10-14 15:15:35 -07:00
2020-10-14 15:56:58 -07:00
2020-10-15 14:43:29 -07:00
2020-10-13 12:12:44 -07:00
2020-10-13 12:12:44 -07:00
2020-10-15 14:43:29 -07:00
2020-10-13 13:04:41 -07:00
2020-10-15 14:43:29 -07:00
2020-10-15 14:43:29 -07:00
2020-09-25 06:12:15 +02:00
2020-10-15 10:46:16 -07:00
2020-10-14 10:43:24 -07:00
2020-10-15 10:46:16 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 15:15:35 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 10:45:41 -07:00
2020-10-01 22:59:55 +02:00
2020-10-15 11:07:44 -07:00
2020-10-15 14:43:29 -07:00
2020-10-14 15:15:35 -07:00
2020-10-05 13:32:30 +02:00
2020-10-15 14:43:29 -07:00
2020-10-15 14:43:29 -07:00
2020-10-15 10:46:16 -07:00
2020-10-15 10:46:16 -07:00
2020-10-14 15:56:58 -07:00
2020-10-15 14:43:29 -07:00