HID: multitouch: touchscreens also use confidence reports
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 13 Jul 2018 14:13:53 +0000 (16:13 +0200)
committerJiri Kosina <jkosina@suse.cz>
Tue, 17 Jul 2018 13:33:47 +0000 (15:33 +0200)
According to [1] the confidence is used not only by touchpad devices,
but also by touchscreens.

[1] https://docs.microsoft.com/en-us/windows-hardware/design/component-guidelines/touchscreen-required-hid-top-level-collections

Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
[rebased]
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-multitouch.c

index 587369443f505394fbcf7724aacdeb7a79e4b332..3464adab00857d65d4d613e50a4aa5481a85089e 100644 (file)
@@ -734,7 +734,8 @@ static int mt_touch_input_mapping(struct hid_device *hdev, struct hid_input *hi,
                case HID_DG_CONFIDENCE:
                        if ((cls->name == MT_CLS_WIN_8 ||
                                cls->name == MT_CLS_WIN_8_DUAL) &&
-                               field->application == HID_DG_TOUCHPAD)
+                               (field->application == HID_DG_TOUCHPAD ||
+                                field->application == HID_DG_TOUCHSCREEN))
                                app->quirks |= MT_QUIRK_CONFIDENCE;
 
                        if (app->quirks & MT_QUIRK_CONFIDENCE)