This is a note to let you know that I've just added the patch titled

    Input: synaptics - handle spurious release of trackstick buttons

to the 3.19-stable tree which can be found at:
    
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     input-synaptics-handle-spurious-release-of-trackstick-buttons.patch
and it can be found in the queue-3.19 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.


>From ebc80840b850db72f7ae84fbcf77630ae5409629 Mon Sep 17 00:00:00 2001
From: Benjamin Tissoires <[email protected]>
Date: Sun, 8 Mar 2015 22:32:43 -0700
Subject: Input: synaptics - handle spurious release of trackstick buttons

From: Benjamin Tissoires <[email protected]>

commit ebc80840b850db72f7ae84fbcf77630ae5409629 upstream.

The Fimware 8.1 has a bug in which the extra buttons are only sent when the
ExtBit is 1.  This should be fixed in a future FW update which should have
a bump of the minor version.

Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Hans de Goede <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>

---
 drivers/input/mouse/synaptics.c |   33 +++++++++++++++++++++++++--------
 1 file changed, 25 insertions(+), 8 deletions(-)

--- a/drivers/input/mouse/synaptics.c
+++ b/drivers/input/mouse/synaptics.c
@@ -820,14 +820,36 @@ static void synaptics_report_semi_mt_dat
        }
 }
 
-static void synaptics_report_buttons(struct psmouse *psmouse,
-                                    const struct synaptics_hw_state *hw)
+static void synaptics_report_ext_buttons(struct psmouse *psmouse,
+                                        const struct synaptics_hw_state *hw)
 {
        struct input_dev *dev = psmouse->dev;
        struct synaptics_data *priv = psmouse->private;
        int ext_bits = (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) + 1) >> 1;
        int i;
 
+       if (!SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap))
+               return;
+
+       /* Bug in FW 8.1, buttons are reported only when ExtBit is 1 */
+       if (SYN_ID_FULL(priv->identity) == 0x801 &&
+           !((psmouse->packet[0] ^ psmouse->packet[3]) & 0x02))
+               return;
+
+       for (i = 0; i < ext_bits; i++) {
+               input_report_key(dev, BTN_0 + 2 * i,
+                       hw->ext_buttons & (1 << i));
+               input_report_key(dev, BTN_1 + 2 * i,
+                       hw->ext_buttons & (1 << (i + ext_bits)));
+       }
+}
+
+static void synaptics_report_buttons(struct psmouse *psmouse,
+                                    const struct synaptics_hw_state *hw)
+{
+       struct input_dev *dev = psmouse->dev;
+       struct synaptics_data *priv = psmouse->private;
+
        input_report_key(dev, BTN_LEFT, hw->left);
        input_report_key(dev, BTN_RIGHT, hw->right);
 
@@ -839,12 +861,7 @@ static void synaptics_report_buttons(str
                input_report_key(dev, BTN_BACK, hw->down);
        }
 
-       for (i = 0; i < ext_bits; i++) {
-               input_report_key(dev, BTN_0 + 2 * i,
-                                hw->ext_buttons & (1 << i));
-               input_report_key(dev, BTN_1 + 2 * i,
-                                hw->ext_buttons & (1 << (i + ext_bits)));
-       }
+       synaptics_report_ext_buttons(psmouse, hw);
 }
 
 static void synaptics_report_slot(struct input_dev *dev, int slot,


Patches currently in stable-queue which might be from 
[email protected] are

queue-3.19/input-synaptics-query-min-dimensions-for-fw-v8.1.patch
queue-3.19/input-synaptics-fix-middle-button-on-lenovo-2015-products.patch
queue-3.19/input-synaptics-do-not-retrieve-the-board-id-on-old-firmwares.patch
queue-3.19/input-synaptics-handle-spurious-release-of-trackstick-buttons.patch
queue-3.19/input-synaptics-skip-quirks-when-post-2013-dimensions.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to