]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Jun 2014 23:40:52 +0000 (16:40 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 Jun 2014 23:40:52 +0000 (16:40 -0700)
added patches:
alsa-hda-fix-onboard-audio-on-intel-h97-z97-chipsets.patch
alsa-hda-hdmi-set-converter-channel-count-even-without-sink.patch
input-atkbd-fix-keyboard-not-working-on-some-lg-laptops.patch
input-elantech-fix-touchpad-initialization-on-gigabyte-u2442.patch
input-synaptics-add-a-matches_pnp_id-helper-function.patch
input-synaptics-add-min-max-quirk-for-the-thinkpad-w540.patch
input-synaptics-change-min-max-quirk-table-to-pnp-id-matching.patch
input-synaptics-t540p-unify-with-other-len0034-models.patch
trace-module-maintain-a-valid-user-count.patch

queue-3.14/alsa-hda-fix-onboard-audio-on-intel-h97-z97-chipsets.patch [new file with mode: 0644]
queue-3.14/alsa-hda-hdmi-set-converter-channel-count-even-without-sink.patch [new file with mode: 0644]
queue-3.14/input-atkbd-fix-keyboard-not-working-on-some-lg-laptops.patch [new file with mode: 0644]
queue-3.14/input-elantech-fix-touchpad-initialization-on-gigabyte-u2442.patch [new file with mode: 0644]
queue-3.14/input-synaptics-add-a-matches_pnp_id-helper-function.patch [new file with mode: 0644]
queue-3.14/input-synaptics-add-min-max-quirk-for-the-thinkpad-w540.patch [new file with mode: 0644]
queue-3.14/input-synaptics-change-min-max-quirk-table-to-pnp-id-matching.patch [new file with mode: 0644]
queue-3.14/input-synaptics-t540p-unify-with-other-len0034-models.patch [new file with mode: 0644]
queue-3.14/series
queue-3.14/trace-module-maintain-a-valid-user-count.patch [new file with mode: 0644]

diff --git a/queue-3.14/alsa-hda-fix-onboard-audio-on-intel-h97-z97-chipsets.patch b/queue-3.14/alsa-hda-fix-onboard-audio-on-intel-h97-z97-chipsets.patch
new file mode 100644 (file)
index 0000000..5ec3352
--- /dev/null
@@ -0,0 +1,34 @@
+From 77f07800cb456bed6e5c345e6e4e83e8eda62437 Mon Sep 17 00:00:00 2001
+From: Takashi Iwai <tiwai@suse.de>
+Date: Fri, 23 May 2014 09:02:44 +0200
+Subject: ALSA: hda - Fix onboard audio on Intel H97/Z97 chipsets
+
+From: Takashi Iwai <tiwai@suse.de>
+
+commit 77f07800cb456bed6e5c345e6e4e83e8eda62437 upstream.
+
+The recent Intel H97/Z97 chipsets need the similar setups like other
+Intel chipsets for snooping, etc.  Especially without snooping, the
+audio playback stutters or gets corrupted.  This fix patch just adds
+the corresponding PCI ID entry with the proper flags.
+
+Reported-and-tested-by: Arthur Borsboom <arthurborsboom@gmail.com>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/hda_intel.c |    3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/sound/pci/hda/hda_intel.c
++++ b/sound/pci/hda/hda_intel.c
+@@ -3988,6 +3988,9 @@ static DEFINE_PCI_DEVICE_TABLE(azx_ids)
+       /* Lynx Point */
+       { PCI_DEVICE(0x8086, 0x8c20),
+         .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
++      /* 9 Series */
++      { PCI_DEVICE(0x8086, 0x8ca0),
++        .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
+       /* Wellsburg */
+       { PCI_DEVICE(0x8086, 0x8d20),
+         .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH },
diff --git a/queue-3.14/alsa-hda-hdmi-set-converter-channel-count-even-without-sink.patch b/queue-3.14/alsa-hda-hdmi-set-converter-channel-count-even-without-sink.patch
new file mode 100644 (file)
index 0000000..7e8d515
--- /dev/null
@@ -0,0 +1,55 @@
+From f06ab794af7055d0949b09885f79f8b493deec64 Mon Sep 17 00:00:00 2001
+From: Anssi Hannula <anssi.hannula@iki.fi>
+Date: Mon, 5 May 2014 02:38:43 +0300
+Subject: ALSA: hda - hdmi: Set converter channel count even without sink
+
+From: Anssi Hannula <anssi.hannula@iki.fi>
+
+commit f06ab794af7055d0949b09885f79f8b493deec64 upstream.
+
+Since commit 1df5a06a ("ALSA: hda - hdmi: Fix programmed active channel
+count") channel count is no longer being set if monitor_present is 0.
+This is because setting the count was moved after the CA value is
+determined, which is only after the monitor_present check in
+hdmi_setup_audio_infoframe().
+
+Unfortunately, in some cases, such as with a non-spec-compliant codec or
+with a problematic video driver, monitor_present is always 0. As a
+specific example, this seems to happen with gen1 ATV (SiI1390 codec),
+causing left-channel-only stereo playback (multi-channel playback has
+apparently never worked with this codec despite it reporting 8 channels,
+reason unknown).
+
+Simply setting converter channel count without setting the pin infoframe
+and channel mapping as well does not theoretically make much sense as
+this will just mean they are out-of-sync and multichannel playback will
+have a wrong channel mapping.
+
+However, adding back just setting the converter channel count even in
+no-monitor case is the safest change which at least fixes the stereo
+playback regression on SiI1390 codec. Do that.
+
+Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
+Reported-by: Stephan Raue <stephan@openelec.tv>
+Tested-by: Stephan Raue <stephan@openelec.tv>
+Signed-off-by: Takashi Iwai <tiwai@suse.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ sound/pci/hda/patch_hdmi.c |    4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/sound/pci/hda/patch_hdmi.c
++++ b/sound/pci/hda/patch_hdmi.c
+@@ -1123,8 +1123,10 @@ static void hdmi_setup_audio_infoframe(s
+                                           AMP_OUT_UNMUTE);
+       eld = &per_pin->sink_eld;
+-      if (!eld->monitor_present)
++      if (!eld->monitor_present) {
++              hdmi_set_channel_count(codec, per_pin->cvt_nid, channels);
+               return;
++      }
+       if (!non_pcm && per_pin->chmap_set)
+               ca = hdmi_manual_channel_allocation(channels, per_pin->chmap);
diff --git a/queue-3.14/input-atkbd-fix-keyboard-not-working-on-some-lg-laptops.patch b/queue-3.14/input-atkbd-fix-keyboard-not-working-on-some-lg-laptops.patch
new file mode 100644 (file)
index 0000000..996eeb5
--- /dev/null
@@ -0,0 +1,83 @@
+From 3d725caa9dcc78c3dc9e7ea0c04f626468edd9c9 Mon Sep 17 00:00:00 2001
+From: Sheng-Liang Song <ssl@chromium.org>
+Date: Thu, 24 Apr 2014 16:28:29 -0700
+Subject: Input: atkbd - fix keyboard not working on some LG laptops
+
+From: Sheng-Liang Song <ssl@chromium.org>
+
+commit 3d725caa9dcc78c3dc9e7ea0c04f626468edd9c9 upstream.
+
+After issuing ATKBD_CMD_RESET_DIS, keyboard on some LG laptops stops
+working. The workaround is to stop issuing ATKBD_CMD_RESET_DIS commands.
+
+In order to keep changes in atkbd driver to the minimum we check DMI
+signature and only skip ATKBD_CMD_RESET_DIS if we are running on LG
+LW25-B7HV or P1-J273B.
+
+Signed-off-by: Sheng-Liang Song <ssl@chromium.org>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/keyboard/atkbd.c |   29 ++++++++++++++++++++++++++++-
+ 1 file changed, 28 insertions(+), 1 deletion(-)
+
+--- a/drivers/input/keyboard/atkbd.c
++++ b/drivers/input/keyboard/atkbd.c
+@@ -243,6 +243,12 @@ static void (*atkbd_platform_fixup)(stru
+ static void *atkbd_platform_fixup_data;
+ static unsigned int (*atkbd_platform_scancode_fixup)(struct atkbd *, unsigned int);
++/*
++ * Certain keyboards to not like ATKBD_CMD_RESET_DIS and stop responding
++ * to many commands until full reset (ATKBD_CMD_RESET_BAT) is performed.
++ */
++static bool atkbd_skip_deactivate;
++
+ static ssize_t atkbd_attr_show_helper(struct device *dev, char *buf,
+                               ssize_t (*handler)(struct atkbd *, char *));
+ static ssize_t atkbd_attr_set_helper(struct device *dev, const char *buf, size_t count,
+@@ -768,7 +774,8 @@ static int atkbd_probe(struct atkbd *atk
+  * Make sure nothing is coming from the keyboard and disturbs our
+  * internal state.
+  */
+-      atkbd_deactivate(atkbd);
++      if (!atkbd_skip_deactivate)
++              atkbd_deactivate(atkbd);
+       return 0;
+ }
+@@ -1638,6 +1645,12 @@ static int __init atkbd_setup_scancode_f
+       return 1;
+ }
++static int __init atkbd_deactivate_fixup(const struct dmi_system_id *id)
++{
++      atkbd_skip_deactivate = true;
++      return 1;
++}
++
+ static const struct dmi_system_id atkbd_dmi_quirk_table[] __initconst = {
+       {
+               .matches = {
+@@ -1775,6 +1788,20 @@ static const struct dmi_system_id atkbd_
+               .callback = atkbd_setup_scancode_fixup,
+               .driver_data = atkbd_oqo_01plus_scancode_fixup,
+       },
++      {
++              .matches = {
++                      DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
++                      DMI_MATCH(DMI_PRODUCT_NAME, "LW25-B7HV"),
++              },
++              .callback = atkbd_deactivate_fixup,
++      },
++      {
++              .matches = {
++                      DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
++                      DMI_MATCH(DMI_PRODUCT_NAME, "P1-J273B"),
++              },
++              .callback = atkbd_deactivate_fixup,
++      },
+       { }
+ };
diff --git a/queue-3.14/input-elantech-fix-touchpad-initialization-on-gigabyte-u2442.patch b/queue-3.14/input-elantech-fix-touchpad-initialization-on-gigabyte-u2442.patch
new file mode 100644 (file)
index 0000000..adef593
--- /dev/null
@@ -0,0 +1,117 @@
+From 36189cc3cd57ab0f1cd75241f93fe01de928ac06 Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Mon, 5 May 2014 09:36:43 -0700
+Subject: Input: elantech - fix touchpad initialization on Gigabyte U2442
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit 36189cc3cd57ab0f1cd75241f93fe01de928ac06 upstream.
+
+The hw_version 3 Elantech touchpad on the Gigabyte U2442 does not accept
+0x0b as initialization value for r10, this stand-alone version of the
+driver: http://planet76.com/drivers/elantech/psmouse-elantech-v6.tar.bz2
+
+Uses 0x03 which does work, so this means not setting bit 3 of r10 which
+sets: "Enable Real H/W Resolution In Absolute mode"
+
+Which will result in half the x and y resolution we get with that bit set,
+so simply not setting it everywhere is not a solution. We've been unable to
+find a way to identify touchpads where setting the bit will fail, so this
+patch uses a dmi based blacklist for this.
+
+https://bugzilla.kernel.org/show_bug.cgi?id=61151
+
+Reported-by: Philipp Wolfer <ph.wolfer@gmail.com>
+Tested-by: Philipp Wolfer <ph.wolfer@gmail.com>
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ Documentation/input/elantech.txt |    5 ++++-
+ drivers/input/mouse/elantech.c   |   26 +++++++++++++++++++++++++-
+ drivers/input/mouse/elantech.h   |    1 +
+ 3 files changed, 30 insertions(+), 2 deletions(-)
+
+--- a/Documentation/input/elantech.txt
++++ b/Documentation/input/elantech.txt
+@@ -504,9 +504,12 @@ byte 5:
+ * reg_10
+    bit   7   6   5   4   3   2   1   0
+-         0   0   0   0   0   0   0   A
++         0   0   0   0   R   F   T   A
+          A: 1 = enable absolute tracking
++         T: 1 = enable two finger mode auto correct
++         F: 1 = disable ABS Position Filter
++         R: 1 = enable real hardware resolution
+ 6.2 Native absolute mode 6 byte packet format
+     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+--- a/drivers/input/mouse/elantech.c
++++ b/drivers/input/mouse/elantech.c
+@@ -11,6 +11,7 @@
+  */
+ #include <linux/delay.h>
++#include <linux/dmi.h>
+ #include <linux/slab.h>
+ #include <linux/module.h>
+ #include <linux/input.h>
+@@ -831,7 +832,11 @@ static int elantech_set_absolute_mode(st
+               break;
+       case 3:
+-              etd->reg_10 = 0x0b;
++              if (etd->set_hw_resolution)
++                      etd->reg_10 = 0x0b;
++              else
++                      etd->reg_10 = 0x03;
++
+               if (elantech_write_reg(psmouse, 0x10, etd->reg_10))
+                       rc = -1;
+@@ -1331,6 +1336,22 @@ static int elantech_reconnect(struct psm
+ }
+ /*
++ * Some hw_version 3 models go into error state when we try to set bit 3 of r10
++ */
++static const struct dmi_system_id no_hw_res_dmi_table[] = {
++#if defined(CONFIG_DMI) && defined(CONFIG_X86)
++      {
++              /* Gigabyte U2442 */
++              .matches = {
++                      DMI_MATCH(DMI_SYS_VENDOR, "GIGABYTE"),
++                      DMI_MATCH(DMI_PRODUCT_NAME, "U2442"),
++              },
++      },
++#endif
++      { }
++};
++
++/*
+  * determine hardware version and set some properties according to it.
+  */
+ static int elantech_set_properties(struct elantech_data *etd)
+@@ -1389,6 +1410,9 @@ static int elantech_set_properties(struc
+        */
+       etd->crc_enabled = ((etd->fw_version & 0x4000) == 0x4000);
++      /* Enable real hardware resolution on hw_version 3 ? */
++      etd->set_hw_resolution = !dmi_check_system(no_hw_res_dmi_table);
++
+       return 0;
+ }
+--- a/drivers/input/mouse/elantech.h
++++ b/drivers/input/mouse/elantech.h
+@@ -130,6 +130,7 @@ struct elantech_data {
+       bool jumpy_cursor;
+       bool reports_pressure;
+       bool crc_enabled;
++      bool set_hw_resolution;
+       unsigned char hw_version;
+       unsigned int fw_version;
+       unsigned int single_finger_reports;
diff --git a/queue-3.14/input-synaptics-add-a-matches_pnp_id-helper-function.patch b/queue-3.14/input-synaptics-add-a-matches_pnp_id-helper-function.patch
new file mode 100644 (file)
index 0000000..dad6e6e
--- /dev/null
@@ -0,0 +1,61 @@
+From e2f611029b370bb7a04236215ad4b36aa8cb98cd Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Mon, 19 May 2014 22:53:23 -0700
+Subject: Input: synaptics - add a matches_pnp_id helper function
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit e2f611029b370bb7a04236215ad4b36aa8cb98cd upstream.
+
+This is a preparation patch for simplifying the min/max quirk table.
+
+Cc: stable@vger.kernel.org
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/mouse/synaptics.c |   25 ++++++++++++++-----------
+ 1 file changed, 14 insertions(+), 11 deletions(-)
+
+--- a/drivers/input/mouse/synaptics.c
++++ b/drivers/input/mouse/synaptics.c
+@@ -156,6 +156,18 @@ static const char * const topbuttonpad_p
+       NULL
+ };
++static bool matches_pnp_id(struct psmouse *psmouse, const char * const ids[])
++{
++      int i;
++
++      if (!strncmp(psmouse->ps2dev.serio->firmware_id, "PNP:", 4))
++              for (i = 0; ids[i]; i++)
++                      if (strstr(psmouse->ps2dev.serio->firmware_id, ids[i]))
++                              return true;
++
++      return false;
++}
++
+ /*****************************************************************************
+  *    Synaptics communications functions
+  ****************************************************************************/
+@@ -1365,17 +1377,8 @@ static void set_input_params(struct psmo
+       if (SYN_CAP_CLICKPAD(priv->ext_cap_0c)) {
+               __set_bit(INPUT_PROP_BUTTONPAD, dev->propbit);
+-              /* See if this buttonpad has a top button area */
+-              if (!strncmp(psmouse->ps2dev.serio->firmware_id, "PNP:", 4)) {
+-                      for (i = 0; topbuttonpad_pnp_ids[i]; i++) {
+-                              if (strstr(psmouse->ps2dev.serio->firmware_id,
+-                                         topbuttonpad_pnp_ids[i])) {
+-                                      __set_bit(INPUT_PROP_TOPBUTTONPAD,
+-                                                dev->propbit);
+-                                      break;
+-                              }
+-                      }
+-              }
++              if (matches_pnp_id(psmouse, topbuttonpad_pnp_ids))
++                      __set_bit(INPUT_PROP_TOPBUTTONPAD, dev->propbit);
+               /* Clickpads report only left button */
+               __clear_bit(BTN_RIGHT, dev->keybit);
+               __clear_bit(BTN_MIDDLE, dev->keybit);
diff --git a/queue-3.14/input-synaptics-add-min-max-quirk-for-the-thinkpad-w540.patch b/queue-3.14/input-synaptics-add-min-max-quirk-for-the-thinkpad-w540.patch
new file mode 100644 (file)
index 0000000..a7b5179
--- /dev/null
@@ -0,0 +1,37 @@
+From 0b5fe736fe923f1f5e05413878d5990e92ffbdf5 Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Wed, 14 May 2014 11:10:40 -0700
+Subject: Input: synaptics - add min/max quirk for the ThinkPad W540
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit 0b5fe736fe923f1f5e05413878d5990e92ffbdf5 upstream.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=1096436
+
+Tested-and-reported-by: ajayr@bigfoot.com
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/mouse/synaptics.c |    8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+--- a/drivers/input/mouse/synaptics.c
++++ b/drivers/input/mouse/synaptics.c
+@@ -1614,6 +1614,14 @@ static const struct dmi_system_id min_ma
+               .driver_data = (int []){1024, 5112, 2024, 4832},
+       },
+       {
++              /* Lenovo ThinkPad W540 */
++              .matches = {
++                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
++                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad W540"),
++              },
++              .driver_data = (int []){1024, 5112, 2024, 4832},
++      },
++      {
+               /* Lenovo Yoga S1 */
+               .matches = {
+                       DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
diff --git a/queue-3.14/input-synaptics-change-min-max-quirk-table-to-pnp-id-matching.patch b/queue-3.14/input-synaptics-change-min-max-quirk-table-to-pnp-id-matching.patch
new file mode 100644 (file)
index 0000000..68416e8
--- /dev/null
@@ -0,0 +1,222 @@
+From 0f68f39c393bc06ac5ccc8794f0e2ed841e41c3e Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Mon, 19 May 2014 22:54:09 -0700
+Subject: Input: synaptics - change min/max quirk table to pnp-id matching
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit 0f68f39c393bc06ac5ccc8794f0e2ed841e41c3e upstream.
+
+Most of the affected models share pnp-ids for the touchpad. So switching
+to pnp-ids give us 2 advantages:
+1) It shrinks the quirk list
+2) It will lower the new quirk addition frequency, ie the recently added W540
+   quirk would not have been necessary since it uses the same LEN0034 pnp ids
+   as other models already added before it
+
+As an added bonus it actually puts the quirk on the actual psmouse, rather
+then on the machine, which is technically more correct.
+
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/mouse/synaptics.c |  149 +++++++++-------------------------------
+ 1 file changed, 36 insertions(+), 113 deletions(-)
+
+--- a/drivers/input/mouse/synaptics.c
++++ b/drivers/input/mouse/synaptics.c
+@@ -117,6 +117,31 @@ void synaptics_reset(struct psmouse *psm
+ }
+ #ifdef CONFIG_MOUSE_PS2_SYNAPTICS
++struct min_max_quirk {
++      const char * const *pnp_ids;
++      int x_min, x_max, y_min, y_max;
++};
++
++static const struct min_max_quirk min_max_pnpid_table[] = {
++      {
++              (const char * const []){"LEN0033", NULL},
++              1024, 5052, 2258, 4832
++      },
++      {
++              (const char * const []){"LEN0035", "LEN0042", NULL},
++              1232, 5710, 1156, 4696
++      },
++      {
++              (const char * const []){"LEN0034", "LEN0036", "LEN2004", NULL},
++              1024, 5112, 2024, 4832
++      },
++      {
++              (const char * const []){"LEN2001", NULL},
++              1024, 5022, 2508, 4832
++      },
++      { }
++};
++
+ /* This list has been kindly provided by Synaptics. */
+ static const char * const topbuttonpad_pnp_ids[] = {
+       "LEN0017",
+@@ -129,7 +154,7 @@ static const char * const topbuttonpad_p
+       "LEN002D",
+       "LEN002E",
+       "LEN0033", /* Helix */
+-      "LEN0034", /* T431s, T540, X1 Carbon 2nd */
++      "LEN0034", /* T431s, L440, L540, T540, W540, X1 Carbon 2nd */
+       "LEN0035", /* X240 */
+       "LEN0036", /* T440 */
+       "LEN0037",
+@@ -142,7 +167,7 @@ static const char * const topbuttonpad_p
+       "LEN0048",
+       "LEN0049",
+       "LEN2000",
+-      "LEN2001",
++      "LEN2001", /* Edge E431 */
+       "LEN2002",
+       "LEN2003",
+       "LEN2004", /* L440 */
+@@ -316,20 +341,20 @@ static int synaptics_identify(struct psm
+  * Resolution is left zero if touchpad does not support the query
+  */
+-static const int *quirk_min_max;
+-
+ static int synaptics_resolution(struct psmouse *psmouse)
+ {
+       struct synaptics_data *priv = psmouse->private;
+       unsigned char resp[3];
++      int i;
+-      if (quirk_min_max) {
+-              priv->x_min = quirk_min_max[0];
+-              priv->x_max = quirk_min_max[1];
+-              priv->y_min = quirk_min_max[2];
+-              priv->y_max = quirk_min_max[3];
+-              return 0;
+-      }
++      for (i = 0; min_max_pnpid_table[i].pnp_ids; i++)
++              if (matches_pnp_id(psmouse, min_max_pnpid_table[i].pnp_ids)) {
++                      priv->x_min = min_max_pnpid_table[i].x_min;
++                      priv->x_max = min_max_pnpid_table[i].x_max;
++                      priv->y_min = min_max_pnpid_table[i].y_min;
++                      priv->y_max = min_max_pnpid_table[i].y_max;
++                      return 0;
++              }
+       if (SYN_ID_MAJOR(priv->identity) < 4)
+               return 0;
+@@ -1550,112 +1575,10 @@ static const struct dmi_system_id olpc_d
+       { }
+ };
+-static const struct dmi_system_id min_max_dmi_table[] __initconst = {
+-#if defined(CONFIG_DMI)
+-      {
+-              /* Lenovo ThinkPad Helix */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad Helix"),
+-              },
+-              .driver_data = (int []){1024, 5052, 2258, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad X240 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad X240"),
+-              },
+-              .driver_data = (int []){1232, 5710, 1156, 4696},
+-      },
+-      {
+-              /* Lenovo ThinkPad Edge E431 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad Edge E431"),
+-              },
+-              .driver_data = (int []){1024, 5022, 2508, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad T431s */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad T431"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad T440s */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad T440"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad L440 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad L440"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad T540p */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad T540"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad L540 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad L540"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo ThinkPad W540 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad W540"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-      {
+-              /* Lenovo Yoga S1 */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_EXACT_MATCH(DMI_PRODUCT_VERSION,
+-                                      "ThinkPad S1 Yoga"),
+-              },
+-              .driver_data = (int []){1232, 5710, 1156, 4696},
+-      },
+-      {
+-              /* Lenovo ThinkPad X1 Carbon Haswell (3rd generation) */
+-              .matches = {
+-                      DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+-                      DMI_MATCH(DMI_PRODUCT_VERSION,
+-                                      "ThinkPad X1 Carbon 2nd"),
+-              },
+-              .driver_data = (int []){1024, 5112, 2024, 4832},
+-      },
+-#endif
+-      { }
+-};
+-
+ void __init synaptics_module_init(void)
+ {
+-      const struct dmi_system_id *min_max_dmi;
+-
+       impaired_toshiba_kbc = dmi_check_system(toshiba_dmi_table);
+       broken_olpc_ec = dmi_check_system(olpc_dmi_table);
+-
+-      min_max_dmi = dmi_first_match(min_max_dmi_table);
+-      if (min_max_dmi)
+-              quirk_min_max = min_max_dmi->driver_data;
+ }
+ static int __synaptics_init(struct psmouse *psmouse, bool absolute_mode)
diff --git a/queue-3.14/input-synaptics-t540p-unify-with-other-len0034-models.patch b/queue-3.14/input-synaptics-t540p-unify-with-other-len0034-models.patch
new file mode 100644 (file)
index 0000000..e84aa89
--- /dev/null
@@ -0,0 +1,34 @@
+From 6d396ede224dc596d92d7cab433713536e68916c Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Mon, 19 May 2014 22:52:30 -0700
+Subject: Input: synaptics - T540p - unify with other LEN0034 models
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit 6d396ede224dc596d92d7cab433713536e68916c upstream.
+
+The T540p has a touchpad with pnp-id LEN0034, all the models with this
+pnp-id have the same min/max values, except the T540p where the values are
+slightly off. Fix them to be identical.
+
+This is a preparation patch for simplifying the quirk table.
+
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/input/mouse/synaptics.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/input/mouse/synaptics.c
++++ b/drivers/input/mouse/synaptics.c
+@@ -1603,7 +1603,7 @@ static const struct dmi_system_id min_ma
+                       DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+                       DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad T540"),
+               },
+-              .driver_data = (int []){1024, 5056, 2058, 4832},
++              .driver_data = (int []){1024, 5112, 2024, 4832},
+       },
+       {
+               /* Lenovo ThinkPad L540 */
index a2abb8f88bee362813577515a8b3bc36f34def07..920e89d26a62383eecc27291edfe6fa2bdd722b8 100644 (file)
@@ -136,3 +136,12 @@ e1000e-fix-no-connectivity-when-driver-loaded-with-cable-out.patch
 ceph-clear-directory-s-completeness-when-creating-file.patch
 autofs-fix-lockref-lookup.patch
 fix-races-between-__d_instantiate-and-checks-of-dentry-flags.patch
+trace-module-maintain-a-valid-user-count.patch
+input-atkbd-fix-keyboard-not-working-on-some-lg-laptops.patch
+input-elantech-fix-touchpad-initialization-on-gigabyte-u2442.patch
+input-synaptics-add-min-max-quirk-for-the-thinkpad-w540.patch
+input-synaptics-t540p-unify-with-other-len0034-models.patch
+input-synaptics-add-a-matches_pnp_id-helper-function.patch
+input-synaptics-change-min-max-quirk-table-to-pnp-id-matching.patch
+alsa-hda-hdmi-set-converter-channel-count-even-without-sink.patch
+alsa-hda-fix-onboard-audio-on-intel-h97-z97-chipsets.patch
diff --git a/queue-3.14/trace-module-maintain-a-valid-user-count.patch b/queue-3.14/trace-module-maintain-a-valid-user-count.patch
new file mode 100644 (file)
index 0000000..6d629c8
--- /dev/null
@@ -0,0 +1,44 @@
+From 098507ae3ec2331476fb52e85d4040c1cc6d0ef4 Mon Sep 17 00:00:00 2001
+From: Romain Izard <romain.izard.pro@gmail.com>
+Date: Tue, 4 Mar 2014 10:09:39 +0100
+Subject: trace: module: Maintain a valid user count
+
+From: Romain Izard <romain.izard.pro@gmail.com>
+
+commit 098507ae3ec2331476fb52e85d4040c1cc6d0ef4 upstream.
+
+The replacement of the 'count' variable by two variables 'incs' and
+'decs' to resolve some race conditions during module unloading was done
+in parallel with some cleanup in the trace subsystem, and was integrated
+as a merge.
+
+Unfortunately, the formula for this replacement was wrong in the tracing
+code, and the refcount in the traces was not usable as a result.
+
+Use 'count = incs - decs' to compute the user count.
+
+Link: http://lkml.kernel.org/p/1393924179-9147-1-git-send-email-romain.izard.pro@gmail.com
+
+Acked-by: Ingo Molnar <mingo@kernel.org>
+Cc: Rusty Russell <rusty@rustcorp.com.au>
+Cc: Frederic Weisbecker <fweisbec@gmail.com>
+Fixes: c1ab9cab7509 "merge conflict resolution"
+Signed-off-by: Romain Izard <romain.izard.pro@gmail.com>
+Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ include/trace/events/module.h |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/include/trace/events/module.h
++++ b/include/trace/events/module.h
+@@ -78,7 +78,7 @@ DECLARE_EVENT_CLASS(module_refcnt,
+       TP_fast_assign(
+               __entry->ip     = ip;
+-              __entry->refcnt = __this_cpu_read(mod->refptr->incs) + __this_cpu_read(mod->refptr->decs);
++              __entry->refcnt = __this_cpu_read(mod->refptr->incs) - __this_cpu_read(mod->refptr->decs);
+               __assign_str(name, mod->name);
+       ),