]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
HID: asus: ROG NKey: Ignore portion of 0x5a report
authorJosh Kilmer <srjek2@gmail.com>
Thu, 28 Jul 2022 17:51:11 +0000 (12:51 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 5 Sep 2022 08:31:29 +0000 (10:31 +0200)
commit2b32e820ccf5a0385e46d1c038b321aba9a5ec2d
tree04b030c76be5e5d141901aa37710d3b5eb9edcf6
parent5b3063adff7da583e61b284beb3308f7588a4c8a
HID: asus: ROG NKey: Ignore portion of 0x5a report

commit 1c0cc9d11c665020cbeb80e660fb8929164407f4 upstream.

On an Asus G513QY, of the 5 bytes in a 0x5a report, only the first byte
is a meaningful keycode. The other bytes are zeroed out or hold garbage
from the last packet sent to the keyboard.

This patch fixes up the report descriptor for this event so that the
general hid code will only process 1 byte for keycodes, avoiding
spurious key events and unmapped Asus vendor usagepage code warnings.

Signed-off-by: Josh Kilmer <srjek2@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hid/hid-asus.c