Home Home > GIT Browse > SLE15
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-06-16 10:44:04 +0200
committerTakashi Iwai <tiwai@suse.de>2019-06-16 10:44:28 +0200
commit0b7a4bded5d03dbca040a6c7c7a15a05bbfa8954 (patch)
treea76320843fde41f223f577532d53b4e1ff2c64d5
parentb69ce9b18a98a3e19212a88bc4a5d23fdc25b335 (diff)
HID: wacom: convert Wacom custom usages to standard HID usages
(bsc#1051510).
-rw-r--r--patches.drivers/HID-wacom-convert-Wacom-custom-usages-to-standard-HI.patch43
-rw-r--r--series.conf1
2 files changed, 44 insertions, 0 deletions
diff --git a/patches.drivers/HID-wacom-convert-Wacom-custom-usages-to-standard-HI.patch b/patches.drivers/HID-wacom-convert-Wacom-custom-usages-to-standard-HI.patch
new file mode 100644
index 0000000000..b1014761e2
--- /dev/null
+++ b/patches.drivers/HID-wacom-convert-Wacom-custom-usages-to-standard-HI.patch
@@ -0,0 +1,43 @@
+From 418b573b431310306db31e445594317ba62f5508 Mon Sep 17 00:00:00 2001
+From: Ping Cheng <pingc@wacom.com>
+Date: Mon, 25 Jun 2018 13:24:36 -0700
+Subject: [PATCH] HID: wacom: convert Wacom custom usages to standard HID usages
+Git-commit: 418b573b431310306db31e445594317ba62f5508
+Patch-mainline: v4.19-rc1
+References: bsc#1051510
+
+Otherwise the switch would not catch the proper usages.
+
+Signed-off-by: Ping Cheng <ping.cheng@wacom.com>
+Reviewed-by: Ping Cheng <ping.cheng@wacom.com>
+Signed-off-by: Jiri Kosina <jkosina@suse.cz>
+Acked-by: Takashi Iwai <tiwai@suse.de>
+
+---
+ drivers/hid/wacom_sys.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/hid/wacom_sys.c b/drivers/hid/wacom_sys.c
+index 3a4cf2666a7c..52e85d21e40f 100644
+--- a/drivers/hid/wacom_sys.c
++++ b/drivers/hid/wacom_sys.c
+@@ -394,6 +394,7 @@ static void wacom_usage_mapping(struct hid_device *hdev,
+ struct wacom_features *features = &wacom->wacom_wac.features;
+ bool finger = WACOM_FINGER_FIELD(field);
+ bool pen = WACOM_PEN_FIELD(field);
++ unsigned equivalent_usage = wacom_equivalent_usage(usage->hid);
+
+ /*
+ * Requiring Stylus Usage will ignore boot mouse
+@@ -409,7 +410,7 @@ static void wacom_usage_mapping(struct hid_device *hdev,
+
+ wacom_hid_usage_quirk(hdev, field, usage);
+
+- switch (usage->hid) {
++ switch (equivalent_usage) {
+ case HID_GD_X:
+ features->x_max = field->logical_maximum;
+ if (finger) {
+--
+2.16.4
+
diff --git a/series.conf b/series.conf
index 98fa3bd665..bbcc51ab65 100644
--- a/series.conf
+++ b/series.conf
@@ -18793,6 +18793,7 @@
patches.drivers/HID-hid-ntrig-add-error-handling-for-sysfs_create_gr.patch
patches.drivers/HID-wacom-Replace-touch_max-fixup-code-with-static-t.patch
patches.drivers/HID-wacom-Move-handling-of-HID-quirks-into-a-dedicat.patch
+ patches.drivers/HID-wacom-convert-Wacom-custom-usages-to-standard-HI.patch
patches.suse/livepatch-validate-module-old-func-name-length.patch
patches.suse/livepatch-remove-reliable-stacktrace-check-in-klp_try_switch_task.patch
patches.drivers/rtc-bq4802-add-error-handling-for-devm_ioremap.patch