linux_4_18: HID: core: fix grouping by application

This patch fixes #45165

commit f07b3c1da92d ("HID: generic: create one input report per
application type") was effectively the same as MULTI_INPUT:
hidinput->report was never set, so hidinput_match_application()
always returned null.

Fix that by testing against the real application.

Note that this breaks some old eGalax touchscreens that expect MULTI_INPUT
instead of HID_QUIRK_INPUT_PER_APP. Enable this quirk for backward
compatibility on all non-Win8 touchscreens.

link: https://bugzilla.kernel.org/show_bug.cgi?id=200847
link: https://bugzilla.kernel.org/show_bug.cgi?id=200849
link: https://bugs.archlinux.org/task/59699
link: https://github.com/NixOS/nixpkgs/issues/45165

Cc: stable@vger.kernel.org # v4.18+
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
This commit is contained in:
Wael M. Nasreddine 2018-09-04 13:29:40 -07:00 committed by Tim Steinbach
parent de825a4eaa
commit 107de747c7

View File

@ -14016,6 +14016,18 @@ with pkgs;
# when adding a new linux version
# kernelPatches.cpu-cgroup-v2."4.11"
kernelPatches.modinst_arg_list_too_long
# https://github.com/NixOS/nixpkgs/issues/45165
# TODO: remove this patch once it is merged upstream and released.
(rec {
name = "hid-core-fix-grouping-by-application";
patch = fetchpatch {
name = name + ".patch";
# https://patchwork.kernel.org/patch/10587369/
url = https://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git/patch/?id=0d6c3011409135ea84e2a231b013a22017ff999a;
sha256 = "0bdrv0aqjh0rdjlaaaqpdgrnd9452fa4ggaa1nq2kmik3q00cq4m";
};
})
];
};