[PATCH 20/25] Input: synaptics - do not retrieve the board id on old firmwares

Timo Aaltonen tjaalton at ubuntu.com
Wed Apr 29 20:24:56 UTC 2015


From: Benjamin Tissoires <benjamin.tissoires at redhat.com>

The board id capability has been added in firmware 7.5.

Cc: stable at vger.kernel.org
Signed-off-by: Benjamin Tissoires <benjamin.tissoires at redhat.com>
Acked-by: Hans de Goede <hdegoede at redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov at gmail.com>
(cherry picked from commit b57a7128be24062b5b5b26032b7cd58f1651547e)
---
 drivers/input/mouse/synaptics.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c
index 4979d39..529b278 100644
--- a/drivers/input/mouse/synaptics.c
+++ b/drivers/input/mouse/synaptics.c
@@ -247,6 +247,10 @@ static int synaptics_board_id(struct psmouse *psmouse)
 	struct synaptics_data *priv = psmouse->private;
 	unsigned char bid[3];
 
+	/* firmwares prior 7.5 have no board_id encoded */
+	if (SYN_ID_FULL(priv->identity) < 0x705)
+		return 0;
+
 	if (synaptics_send_cmd(psmouse, SYN_QUE_MODES, bid))
 		return -1;
 	priv->board_id = ((bid[0] & 0xfc) << 6) | bid[1];
-- 
2.1.4





More information about the kernel-team mailing list