diff options
| author | Benjamin Tissoires <benjamin.tissoires@redhat.com> | 2017-05-26 19:21:36 -0400 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2017-05-29 23:00:25 -0400 |
| commit | f4101ff87dafd22fbcc3547fd3a3a3717d3d72d3 (patch) | |
| tree | 53aeecff269ab94cb9e46456472dabe4a7ae0b51 | |
| parent | f4947d79a7080b25829997eeee38d4d65137c161 (diff) | |
Input: synaptics - warn the users when there is a better mode
The Synaptics touchpads are now either using i2c-hid or rmi-smbus.
Warn the users if they are missing the rmi-smbus modules and have no
chance of reporting correct data.
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
| -rw-r--r-- | drivers/input/mouse/synaptics.c | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c index 9b27a6c710b2..604aa3aa7284 100644 --- a/drivers/input/mouse/synaptics.c +++ b/drivers/input/mouse/synaptics.c | |||
| @@ -176,6 +176,12 @@ static const char * const smbus_pnp_ids[] = { | |||
| 176 | NULL | 176 | NULL |
| 177 | }; | 177 | }; |
| 178 | 178 | ||
| 179 | static const char * const forcepad_pnp_ids[] = { | ||
| 180 | "SYN300D", | ||
| 181 | "SYN3014", | ||
| 182 | NULL | ||
| 183 | }; | ||
| 184 | |||
| 179 | /* | 185 | /* |
| 180 | * Send a command to the synpatics touchpad by special commands | 186 | * Send a command to the synpatics touchpad by special commands |
| 181 | */ | 187 | */ |
| @@ -482,13 +488,6 @@ static const struct min_max_quirk min_max_pnpid_table[] = { | |||
| 482 | { } | 488 | { } |
| 483 | }; | 489 | }; |
| 484 | 490 | ||
| 485 | /* This list has been kindly provided by Synaptics. */ | ||
| 486 | static const char * const forcepad_pnp_ids[] = { | ||
| 487 | "SYN300D", | ||
| 488 | "SYN3014", | ||
| 489 | NULL | ||
| 490 | }; | ||
| 491 | |||
| 492 | /***************************************************************************** | 491 | /***************************************************************************** |
| 493 | * Synaptics communications functions | 492 | * Synaptics communications functions |
| 494 | ****************************************************************************/ | 493 | ****************************************************************************/ |
| @@ -1813,6 +1812,15 @@ int synaptics_init(struct psmouse *psmouse) | |||
| 1813 | } | 1812 | } |
| 1814 | 1813 | ||
| 1815 | if (SYN_CAP_INTERTOUCH(info.ext_cap_0c)) { | 1814 | if (SYN_CAP_INTERTOUCH(info.ext_cap_0c)) { |
| 1815 | if ((!IS_ENABLED(CONFIG_RMI4_SMB) || | ||
| 1816 | !IS_ENABLED(CONFIG_MOUSE_PS2_SYNAPTICS_SMBUS)) && | ||
| 1817 | /* Forcepads need F21, which is not ready */ | ||
| 1818 | !psmouse_matches_pnp_id(psmouse, forcepad_pnp_ids)) { | ||
| 1819 | psmouse_warn(psmouse, | ||
| 1820 | "The touchpad can support a better bus than the too old PS/2 protocol. " | ||
| 1821 | "Make sure MOUSE_PS2_SYNAPTICS_SMBUS and RMI4_SMB are enabled to get a better touchpad experience.\n"); | ||
| 1822 | } | ||
| 1823 | |||
| 1816 | error = synaptics_setup_intertouch(psmouse, &info, true); | 1824 | error = synaptics_setup_intertouch(psmouse, &info, true); |
| 1817 | if (!error) | 1825 | if (!error) |
| 1818 | return PSMOUSE_SYNAPTICS_SMBUS; | 1826 | return PSMOUSE_SYNAPTICS_SMBUS; |
