ACK: [PATCH] Input: trackpoint - add new trackpoint firmware ID
Po-Hsu Lin
po-hsu.lin at canonical.com
Wed Sep 27 09:17:34 UTC 2017
On Wed, Sep 27, 2017 at 4:43 PM, Aaron Ma <aaron.ma at canonical.com> wrote:
> BugLink: https://launchpad.net/bugs/1715271
>
> Synaptics add new TP firmware ID: 0x2 and 0x3, for now both lower 2 bits
> are indicated as TP. Change the constant to bitwise values.
>
> This makes trackpoint to be recognized on Lenovo Carbon X1 Gen5 instead
> of it being identified as "PS/2 Generic Mouse".
>
> Signed-off-by: Aaron Ma <aaron.ma at canonical.com>
> Cc: stable at vger.kernel.org
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov at gmail.com>
> (cherry picked from commit ec667683c532c93fb41e100e5d61a518971060e2)
> Signed-off-by: Aaron Ma <aaron.ma at canonical.com>
Clean cherry-pick, well explained for why it's only targeting on Zesty.
Acked-by: Po-Hsu Lin <po-hsu.lin at canonical.com>
> ---
> drivers/input/mouse/trackpoint.c | 3 ++-
> drivers/input/mouse/trackpoint.h | 3 ++-
> 2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/input/mouse/trackpoint.c b/drivers/input/mouse/trackpoint.c
> index ed6f9565aa76..4074fd5e3781 100644
> --- a/drivers/input/mouse/trackpoint.c
> +++ b/drivers/input/mouse/trackpoint.c
> @@ -265,7 +265,8 @@ static int trackpoint_start_protocol(struct psmouse *psmouse, unsigned char *fir
> if (ps2_command(&psmouse->ps2dev, param, MAKE_PS2_CMD(0, 2, TP_READ_ID)))
> return -1;
>
> - if (param[0] != TP_MAGIC_IDENT)
> + /* add new TP ID. */
> + if (!(param[0] & TP_MAGIC_IDENT))
> return -1;
>
> if (firmware_id)
> diff --git a/drivers/input/mouse/trackpoint.h b/drivers/input/mouse/trackpoint.h
> index 5617ed3a7d7a..88055755f82e 100644
> --- a/drivers/input/mouse/trackpoint.h
> +++ b/drivers/input/mouse/trackpoint.h
> @@ -21,8 +21,9 @@
> #define TP_COMMAND 0xE2 /* Commands start with this */
>
> #define TP_READ_ID 0xE1 /* Sent for device identification */
> -#define TP_MAGIC_IDENT 0x01 /* Sent after a TP_READ_ID followed */
> +#define TP_MAGIC_IDENT 0x03 /* Sent after a TP_READ_ID followed */
> /* by the firmware ID */
> + /* Firmware ID includes 0x1, 0x2, 0x3 */
>
>
> /*
> --
> 2.13.5
>
>
> --
> kernel-team mailing list
> kernel-team at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
More information about the kernel-team
mailing list