]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Sep 2019 11:14:13 +0000 (13:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Sep 2019 11:14:13 +0000 (13:14 +0200)
added patches:
hid-wacom-generic-read-hid_dg_contactmax-from-any-feature-report.patch
input-elan_i2c-remove-lenovo-legion-y7000-pnpid.patch
powerpc-mm-radix-use-the-right-page-size-for-vmemmap-mapping.patch

queue-4.14/hid-wacom-generic-read-hid_dg_contactmax-from-any-feature-report.patch [new file with mode: 0644]
queue-4.14/input-elan_i2c-remove-lenovo-legion-y7000-pnpid.patch [new file with mode: 0644]
queue-4.14/powerpc-mm-radix-use-the-right-page-size-for-vmemmap-mapping.patch [new file with mode: 0644]
queue-4.14/series [new file with mode: 0644]

diff --git a/queue-4.14/hid-wacom-generic-read-hid_dg_contactmax-from-any-feature-report.patch b/queue-4.14/hid-wacom-generic-read-hid_dg_contactmax-from-any-feature-report.patch
new file mode 100644 (file)
index 0000000..70a881a
--- /dev/null
@@ -0,0 +1,74 @@
+From 184eccd40389df29abefab88092c4ff33191fd0c Mon Sep 17 00:00:00 2001
+From: Aaron Armstrong Skomra <skomra@gmail.com>
+Date: Wed, 12 Jun 2019 14:19:29 -0700
+Subject: HID: wacom: generic: read HID_DG_CONTACTMAX from any feature report
+
+From: Aaron Armstrong Skomra <skomra@gmail.com>
+
+commit 184eccd40389df29abefab88092c4ff33191fd0c upstream.
+
+In the generic code path, HID_DG_CONTACTMAX was previously
+only read from the second byte of report 0x23.
+
+Another report (0x82) has the HID_DG_CONTACTMAX in the
+higher nibble of the third byte. We should support reading the
+value of HID_DG_CONTACTMAX no matter what report we are reading
+or which position that value is in.
+
+To do this we submit the feature report as a event report
+using hid_report_raw_event(). Our modified finger event path
+records the value of HID_DG_CONTACTMAX when it sees that usage.
+
+Fixes: 8ffffd5212846 ("HID: wacom: fix timeout on probe for some wacoms")
+Signed-off-by: Aaron Armstrong Skomra <aaron.skomra@wacom.com>
+Signed-off-by: Jiri Kosina <jkosina@suse.cz>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/hid/wacom_sys.c |   10 ++++++----
+ drivers/hid/wacom_wac.c |    4 ++++
+ 2 files changed, 10 insertions(+), 4 deletions(-)
+
+--- a/drivers/hid/wacom_sys.c
++++ b/drivers/hid/wacom_sys.c
+@@ -125,14 +125,16 @@ static void wacom_feature_mapping(struct
+               /* leave touch_max as is if predefined */
+               if (!features->touch_max) {
+                       /* read manually */
+-                      data = kzalloc(2, GFP_KERNEL);
++                      n = hid_report_len(field->report);
++                      data = hid_alloc_report_buf(field->report, GFP_KERNEL);
+                       if (!data)
+                               break;
+                       data[0] = field->report->id;
+                       ret = wacom_get_report(hdev, HID_FEATURE_REPORT,
+-                                              data, 2, WAC_CMD_RETRIES);
+-                      if (ret == 2) {
+-                              features->touch_max = data[1];
++                                             data, n, WAC_CMD_RETRIES);
++                      if (ret == n) {
++                              ret = hid_report_raw_event(hdev,
++                                      HID_FEATURE_REPORT, data, n, 0);
+                       } else {
+                               features->touch_max = 16;
+                               hid_warn(hdev, "wacom_feature_mapping: "
+--- a/drivers/hid/wacom_wac.c
++++ b/drivers/hid/wacom_wac.c
+@@ -2428,6 +2428,7 @@ static void wacom_wac_finger_event(struc
+       struct wacom *wacom = hid_get_drvdata(hdev);
+       struct wacom_wac *wacom_wac = &wacom->wacom_wac;
+       unsigned equivalent_usage = wacom_equivalent_usage(usage->hid);
++      struct wacom_features *features = &wacom->wacom_wac.features;
+       switch (equivalent_usage) {
+       case HID_GD_X:
+@@ -2448,6 +2449,9 @@ static void wacom_wac_finger_event(struc
+       case HID_DG_TIPSWITCH:
+               wacom_wac->hid_data.tipswitch = value;
+               break;
++      case HID_DG_CONTACTMAX:
++              features->touch_max = value;
++              return;
+       }
diff --git a/queue-4.14/input-elan_i2c-remove-lenovo-legion-y7000-pnpid.patch b/queue-4.14/input-elan_i2c-remove-lenovo-legion-y7000-pnpid.patch
new file mode 100644 (file)
index 0000000..60d3f8b
--- /dev/null
@@ -0,0 +1,36 @@
+From 0c043d70d04711fe6c380df9065fdc44192c49bf Mon Sep 17 00:00:00 2001
+From: Benjamin Tissoires <benjamin.tissoires@redhat.com>
+Date: Fri, 6 Sep 2019 12:02:32 -0700
+Subject: Input: elan_i2c - remove Lenovo Legion Y7000 PnpID
+
+From: Benjamin Tissoires <benjamin.tissoires@redhat.com>
+
+commit 0c043d70d04711fe6c380df9065fdc44192c49bf upstream.
+
+Looks like the Bios of the Lenovo Legion Y7000 is using ELAN061B
+when the actual device is supposed to be used with hid-multitouch.
+
+Remove it from the list of the supported device, hoping that
+no one will complain about the loss in functionality.
+
+Link: https://bugzilla.kernel.org/show_bug.cgi?id=203467
+Fixes: 738c06d0e456 ("Input: elan_i2c - add hardware ID for multiple Lenovo laptops")
+Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/mouse/elan_i2c_core.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/input/mouse/elan_i2c_core.c
++++ b/drivers/input/mouse/elan_i2c_core.c
+@@ -1274,7 +1274,7 @@ static const struct acpi_device_id elan_
+       { "ELAN0618", 0 },
+       { "ELAN0619", 0 },
+       { "ELAN061A", 0 },
+-      { "ELAN061B", 0 },
++/*    { "ELAN061B", 0 }, not working on the Lenovo Legion Y7000 */
+       { "ELAN061C", 0 },
+       { "ELAN061D", 0 },
+       { "ELAN061E", 0 },
diff --git a/queue-4.14/powerpc-mm-radix-use-the-right-page-size-for-vmemmap-mapping.patch b/queue-4.14/powerpc-mm-radix-use-the-right-page-size-for-vmemmap-mapping.patch
new file mode 100644 (file)
index 0000000..67b3b76
--- /dev/null
@@ -0,0 +1,58 @@
+From 89a3496e0664577043666791ec07fb731d57c950 Mon Sep 17 00:00:00 2001
+From: "Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com>
+Date: Mon, 1 Jul 2019 20:04:42 +0530
+Subject: powerpc/mm/radix: Use the right page size for vmemmap mapping
+
+From: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
+
+commit 89a3496e0664577043666791ec07fb731d57c950 upstream.
+
+We use mmu_vmemmap_psize to find the page size for mapping the vmmemap area.
+With radix translation, we are suboptimally setting this value to PAGE_SIZE.
+
+We do check for 2M page size support and update mmu_vmemap_psize to use
+hugepage size but we suboptimally reset the value to PAGE_SIZE in
+radix__early_init_mmu(). This resulted in always mapping vmemmap area with
+64K page size.
+
+Fixes: 2bfd65e45e87 ("powerpc/mm/radix: Add radix callbacks for early init routines")
+Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
+Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/powerpc/mm/pgtable-radix.c |   16 +++++++---------
+ 1 file changed, 7 insertions(+), 9 deletions(-)
+
+--- a/arch/powerpc/mm/pgtable-radix.c
++++ b/arch/powerpc/mm/pgtable-radix.c
+@@ -442,14 +442,6 @@ void __init radix__early_init_devtree(vo
+       mmu_psize_defs[MMU_PAGE_64K].shift = 16;
+       mmu_psize_defs[MMU_PAGE_64K].ap = 0x5;
+ found:
+-#ifdef CONFIG_SPARSEMEM_VMEMMAP
+-      if (mmu_psize_defs[MMU_PAGE_2M].shift) {
+-              /*
+-               * map vmemmap using 2M if available
+-               */
+-              mmu_vmemmap_psize = MMU_PAGE_2M;
+-      }
+-#endif /* CONFIG_SPARSEMEM_VMEMMAP */
+       return;
+ }
+@@ -527,7 +519,13 @@ void __init radix__early_init_mmu(void)
+ #ifdef CONFIG_SPARSEMEM_VMEMMAP
+       /* vmemmap mapping */
+-      mmu_vmemmap_psize = mmu_virtual_psize;
++      if (mmu_psize_defs[MMU_PAGE_2M].shift) {
++              /*
++               * map vmemmap using 2M if available
++               */
++              mmu_vmemmap_psize = MMU_PAGE_2M;
++      } else
++              mmu_vmemmap_psize = mmu_virtual_psize;
+ #endif
+       /*
+        * initialize page table size
diff --git a/queue-4.14/series b/queue-4.14/series
new file mode 100644 (file)
index 0000000..7ba6360
--- /dev/null
@@ -0,0 +1,3 @@
+hid-wacom-generic-read-hid_dg_contactmax-from-any-feature-report.patch
+input-elan_i2c-remove-lenovo-legion-y7000-pnpid.patch
+powerpc-mm-radix-use-the-right-page-size-for-vmemmap-mapping.patch