]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 5 May 2021 07:59:44 +0000 (09:59 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 5 May 2021 07:59:44 +0000 (09:59 +0200)
added patches:
alsa-usb-audio-add-midi-quirk-for-vox-tonelab-ex.patch
platform-x86-thinkpad_acpi-correct-thermal-sensor-allocation.patch
usb-add-lpm-quirk-for-lenovo-thinkpad-usb-c-dock-gen2-ethernet.patch
usb-add-reset-resume-quirk-for-wd19-s-realtek-hub.patch

queue-4.4/alsa-usb-audio-add-midi-quirk-for-vox-tonelab-ex.patch [new file with mode: 0644]
queue-4.4/platform-x86-thinkpad_acpi-correct-thermal-sensor-allocation.patch [new file with mode: 0644]
queue-4.4/series
queue-4.4/usb-add-lpm-quirk-for-lenovo-thinkpad-usb-c-dock-gen2-ethernet.patch [new file with mode: 0644]
queue-4.4/usb-add-reset-resume-quirk-for-wd19-s-realtek-hub.patch [new file with mode: 0644]

diff --git a/queue-4.4/alsa-usb-audio-add-midi-quirk-for-vox-tonelab-ex.patch b/queue-4.4/alsa-usb-audio-add-midi-quirk-for-vox-tonelab-ex.patch
new file mode 100644 (file)
index 0000000..203b90d
--- /dev/null
@@ -0,0 +1,40 @@
+From 64f40f9be14106e7df0098c427cb60be645bddb7 Mon Sep 17 00:00:00 2001
+From: Takashi Iwai <tiwai@suse.de>
+Date: Wed, 7 Apr 2021 16:45:49 +0200
+Subject: ALSA: usb-audio: Add MIDI quirk for Vox ToneLab EX
+
+From: Takashi Iwai <tiwai@suse.de>
+
+commit 64f40f9be14106e7df0098c427cb60be645bddb7 upstream.
+
+ToneLab EX guitar pedal device requires the same quirk like ToneLab ST
+for supporting the MIDI.
+
+BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=212593
+Cc: <stable@vger.kernel.org>
+Link: https://lore.kernel.org/r/20210407144549.1530-1-tiwai@suse.de
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ sound/usb/quirks-table.h |   10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+--- a/sound/usb/quirks-table.h
++++ b/sound/usb/quirks-table.h
+@@ -2479,6 +2479,16 @@ YAMAHA_DEVICE(0x7010, "UB99"),
+       }
+ },
++{
++      USB_DEVICE_VENDOR_SPEC(0x0944, 0x0204),
++      .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
++              .vendor_name = "KORG, Inc.",
++              /* .product_name = "ToneLab EX", */
++              .ifnum = 3,
++              .type = QUIRK_MIDI_STANDARD_INTERFACE,
++      }
++},
++
+ /* AKAI devices */
+ {
+       USB_DEVICE(0x09e8, 0x0062),
diff --git a/queue-4.4/platform-x86-thinkpad_acpi-correct-thermal-sensor-allocation.patch b/queue-4.4/platform-x86-thinkpad_acpi-correct-thermal-sensor-allocation.patch
new file mode 100644 (file)
index 0000000..a30a3af
--- /dev/null
@@ -0,0 +1,102 @@
+From 6759e18e5cd8745a5dfc5726e4a3db5281ec1639 Mon Sep 17 00:00:00 2001
+From: Mark Pearson <markpearson@lenovo.com>
+Date: Wed, 7 Apr 2021 17:20:15 -0400
+Subject: platform/x86: thinkpad_acpi: Correct thermal sensor allocation
+
+From: Mark Pearson <markpearson@lenovo.com>
+
+commit 6759e18e5cd8745a5dfc5726e4a3db5281ec1639 upstream.
+
+On recent Thinkpad platforms it was reported that temp sensor 11 was
+always incorrectly displaying 66C. It turns out the reason for this is
+that this location in EC RAM is not a temperature sensor but is the
+power supply ID (offset 0xC2).
+
+Based on feedback from the Lenovo firmware team the EC RAM version can
+be determined and for the current version (3) only the 0x78 to 0x7F
+range is used for temp sensors. I don't have any details for earlier
+versions so I have left the implementation unaltered there.
+
+Note - in this block only 0x78 and 0x79 are officially designated (CPU &
+GPU sensors). The use of the other locations in the block will vary from
+platform to platform; but the existing logic to detect a sensor presence
+holds.
+
+Signed-off-by: Mark Pearson <markpearson@lenovo.com>
+Link: https://lore.kernel.org/r/20210407212015.298222-1-markpearson@lenovo.com
+Reviewed-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/platform/x86/thinkpad_acpi.c |   31 ++++++++++++++++++++++---------
+ 1 file changed, 22 insertions(+), 9 deletions(-)
+
+--- a/drivers/platform/x86/thinkpad_acpi.c
++++ b/drivers/platform/x86/thinkpad_acpi.c
+@@ -5766,6 +5766,7 @@ enum thermal_access_mode {
+ enum { /* TPACPI_THERMAL_TPEC_* */
+       TP_EC_THERMAL_TMP0 = 0x78,      /* ACPI EC regs TMP 0..7 */
+       TP_EC_THERMAL_TMP8 = 0xC0,      /* ACPI EC regs TMP 8..15 */
++      TP_EC_FUNCREV      = 0xEF,      /* ACPI EC Functional revision */
+       TP_EC_THERMAL_TMP_NA = -128,    /* ACPI EC sensor not available */
+       TPACPI_THERMAL_SENSOR_NA = -128000, /* Sensor not available */
+@@ -5964,7 +5965,7 @@ static const struct attribute_group ther
+ static int __init thermal_init(struct ibm_init_struct *iibm)
+ {
+-      u8 t, ta1, ta2;
++      u8 t, ta1, ta2, ver = 0;
+       int i;
+       int acpi_tmp7;
+       int res;
+@@ -5979,7 +5980,14 @@ static int __init thermal_init(struct ib
+                * 0x78-0x7F, 0xC0-0xC7.  Registers return 0x00 for
+                * non-implemented, thermal sensors return 0x80 when
+                * not available
++               * The above rule is unfortunately flawed. This has been seen with
++               * 0xC2 (power supply ID) causing thermal control problems.
++               * The EC version can be determined by offset 0xEF and at least for
++               * version 3 the Lenovo firmware team confirmed that registers 0xC0-0xC7
++               * are not thermal registers.
+                */
++              if (!acpi_ec_read(TP_EC_FUNCREV, &ver))
++                      pr_warn("Thinkpad ACPI EC unable to access EC version\n");
+               ta1 = ta2 = 0;
+               for (i = 0; i < 8; i++) {
+@@ -5989,11 +5997,13 @@ static int __init thermal_init(struct ib
+                               ta1 = 0;
+                               break;
+                       }
+-                      if (acpi_ec_read(TP_EC_THERMAL_TMP8 + i, &t)) {
+-                              ta2 |= t;
+-                      } else {
+-                              ta1 = 0;
+-                              break;
++                      if (ver < 3) {
++                              if (acpi_ec_read(TP_EC_THERMAL_TMP8 + i, &t)) {
++                                      ta2 |= t;
++                              } else {
++                                      ta1 = 0;
++                                      break;
++                              }
+                       }
+               }
+               if (ta1 == 0) {
+@@ -6009,9 +6019,12 @@ static int __init thermal_init(struct ib
+                               thermal_read_mode = TPACPI_THERMAL_NONE;
+                       }
+               } else {
+-                      thermal_read_mode =
+-                          (ta2 != 0) ?
+-                          TPACPI_THERMAL_TPEC_16 : TPACPI_THERMAL_TPEC_8;
++                      if (ver >= 3)
++                              thermal_read_mode = TPACPI_THERMAL_TPEC_8;
++                      else
++                              thermal_read_mode =
++                                      (ta2 != 0) ?
++                                      TPACPI_THERMAL_TPEC_16 : TPACPI_THERMAL_TPEC_8;
+               }
+       } else if (acpi_tmp7) {
+               if (tpacpi_is_ibm() &&
index 2e8f578be22bacdf4a3eaf0e9cb2e7ea4c8a8734..33b381539dce37976830181ff0748003f72abb4a 100644 (file)
@@ -1,3 +1,7 @@
 timerfd-reject-alarm-timerfds-without-cap_wake_alarm.patch
 net-usb-ax88179_178a-initialize-local-variables-before-use.patch
 iwlwifi-fix-softirq-hardirq-disabling-in-iwl_pcie_enqueue_hcmd.patch
+alsa-usb-audio-add-midi-quirk-for-vox-tonelab-ex.patch
+usb-add-lpm-quirk-for-lenovo-thinkpad-usb-c-dock-gen2-ethernet.patch
+usb-add-reset-resume-quirk-for-wd19-s-realtek-hub.patch
+platform-x86-thinkpad_acpi-correct-thermal-sensor-allocation.patch
diff --git a/queue-4.4/usb-add-lpm-quirk-for-lenovo-thinkpad-usb-c-dock-gen2-ethernet.patch b/queue-4.4/usb-add-lpm-quirk-for-lenovo-thinkpad-usb-c-dock-gen2-ethernet.patch
new file mode 100644 (file)
index 0000000..725789b
--- /dev/null
@@ -0,0 +1,36 @@
+From 8f23fe35ff1e5491b4d279323a8209a31f03ae65 Mon Sep 17 00:00:00 2001
+From: Kai-Heng Feng <kai.heng.feng@canonical.com>
+Date: Mon, 12 Apr 2021 21:54:53 +0800
+Subject: USB: Add LPM quirk for Lenovo ThinkPad USB-C Dock Gen2 Ethernet
+
+From: Kai-Heng Feng <kai.heng.feng@canonical.com>
+
+commit 8f23fe35ff1e5491b4d279323a8209a31f03ae65 upstream.
+
+This is another branded 8153 device that doesn't work well with LPM
+enabled:
+[ 400.597506] r8152 5-1.1:1.0 enx482ae3a2a6f0: Tx status -71
+
+So disable LPM to resolve the issue.
+
+Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
+BugLink: https://bugs.launchpad.net/bugs/1922651
+Link: https://lore.kernel.org/r/20210412135455.791971-1-kai.heng.feng@canonical.com
+Cc: stable <stable@vger.kernel.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/usb/core/quirks.c |    3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/drivers/usb/core/quirks.c
++++ b/drivers/usb/core/quirks.c
+@@ -264,6 +264,9 @@ static const struct usb_device_id usb_qu
+       { USB_DEVICE(0x1532, 0x0116), .driver_info =
+                       USB_QUIRK_LINEAR_UFRAME_INTR_BINTERVAL },
++      /* Lenovo ThinkPad USB-C Dock Gen2 Ethernet (RTL8153 GigE) */
++      { USB_DEVICE(0x17ef, 0xa387), .driver_info = USB_QUIRK_NO_LPM },
++
+       /* BUILDWIN Photo Frame */
+       { USB_DEVICE(0x1908, 0x1315), .driver_info =
+                       USB_QUIRK_HONOR_BNUMINTERFACES },
diff --git a/queue-4.4/usb-add-reset-resume-quirk-for-wd19-s-realtek-hub.patch b/queue-4.4/usb-add-reset-resume-quirk-for-wd19-s-realtek-hub.patch
new file mode 100644 (file)
index 0000000..c07d25f
--- /dev/null
@@ -0,0 +1,55 @@
+From ca91fd8c7643d93bfc18a6fec1a0d3972a46a18a Mon Sep 17 00:00:00 2001
+From: Chris Chiu <chris.chiu@canonical.com>
+Date: Wed, 21 Apr 2021 01:46:51 +0800
+Subject: USB: Add reset-resume quirk for WD19's Realtek Hub
+
+From: Chris Chiu <chris.chiu@canonical.com>
+
+commit ca91fd8c7643d93bfc18a6fec1a0d3972a46a18a upstream.
+
+Realtek Hub (0bda:5487) in Dell Dock WD19 sometimes fails to work
+after the system resumes from suspend with remote wakeup enabled
+device connected:
+[ 1947.640907] hub 5-2.3:1.0: hub_ext_port_status failed (err = -71)
+[ 1947.641208] usb 5-2.3-port5: cannot disable (err = -71)
+[ 1947.641401] hub 5-2.3:1.0: hub_ext_port_status failed (err = -71)
+[ 1947.641450] usb 5-2.3-port4: cannot reset (err = -71)
+
+Information of this hub:
+T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 10 Spd=480  MxCh= 5
+D:  Ver= 2.10 Cls=09(hub  ) Sub=00 Prot=02 MxPS=64 #Cfgs=  1
+P:  Vendor=0bda ProdID=5487 Rev= 1.47
+S:  Manufacturer=Dell Inc.
+S:  Product=Dell dock
+C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
+I:  If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=01 Driver=hub
+E:  Ad=81(I) Atr=03(Int.) MxPS=   1 Ivl=256ms
+I:* If#= 0 Alt= 1 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=02 Driver=hub
+E:  Ad=81(I) Atr=03(Int.) MxPS=   1 Ivl=256ms
+
+The failure results from the ETIMEDOUT by chance when turning on
+the suspend feature for the specified port of the hub. The port
+seems to be in an unknown state so the hub_activate during resume
+fails the hub_port_status, then the hub will fail to work.
+
+The quirky hub needs the reset-resume quirk to function correctly.
+
+Acked-by: Alan Stern <stern@rowland.harvard.edu>
+Signed-off-by: Chris Chiu <chris.chiu@canonical.com>
+Cc: stable <stable@vger.kernel.org>
+Link: https://lore.kernel.org/r/20210420174651.6202-1-chris.chiu@canonical.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/usb/core/quirks.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/drivers/usb/core/quirks.c
++++ b/drivers/usb/core/quirks.c
+@@ -245,6 +245,7 @@ static const struct usb_device_id usb_qu
+       /* Realtek hub in Dell WD19 (Type-C) */
+       { USB_DEVICE(0x0bda, 0x0487), .driver_info = USB_QUIRK_NO_LPM },
++      { USB_DEVICE(0x0bda, 0x5487), .driver_info = USB_QUIRK_RESET_RESUME },
+       /* Generic RTL8153 based ethernet adapters */
+       { USB_DEVICE(0x0bda, 0x8153), .driver_info = USB_QUIRK_NO_LPM },