android_kernel_oneplus_msm8998/include
Nicolas Saenz Julienne 5db3c5adf4 HID: core: move Usage Page concatenation to Main item
[ Upstream commit 58e75155009cc800005629955d3482f36a1e0eec ]

As seen on some USB wireless keyboards manufactured by Primax, the HID
parser was using some assumptions that are not always true. In this case
it's s the fact that, inside the scope of a main item, an Usage Page
will always precede an Usage.

The spec is not pretty clear as 6.2.2.7 states "Any usage that follows
is interpreted as a Usage ID and concatenated with the Usage Page".
While 6.2.2.8 states "When the parser encounters a main item it
concatenates the last declared Usage Page with a Usage to form a
complete usage value." Being somewhat contradictory it was decided to
match Window's implementation, which follows 6.2.2.8.

In summary, the patch moves the Usage Page concatenation from the local
item parsing function to the main item parsing function.

Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Reviewed-by: Terry Junge <terry.junge@poly.com>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-06-11 12:24:03 +02:00
..
acpi
asm-generic asm-generic: Fix local variable shadow in __set_fixmap_offset 2019-04-03 06:23:23 +02:00
clocksource
crypto
drm
dt-bindings
keys KEYS: user: Align the payload buffer 2019-03-23 08:44:17 +01:00
kvm
linux HID: core: move Usage Page concatenation to Main item 2019-06-11 12:24:03 +02:00
math-emu
media
memory
misc
net ipv6: fix a potential deadlock in do_ipv6_setsockopt() 2019-05-16 19:45:05 +02:00
pcmcia
ras
rdma
rxrpc
scsi
soc
sound ALSA: compress: Fix stop handling on compressed capture streams 2019-02-20 10:13:16 +01:00
target
trace ext4: force inode writes when nfsd calls commit_metadata() 2019-01-13 10:05:30 +01:00
uapi x86/speculation: Add prctl() control for indirect branch speculation 2019-05-16 19:45:12 +02:00
video
xen
Kbuild