From: Yunkang Tang Date: Sat, 26 Jul 2014 05:29:24 +0000 (-0700) Subject: Input: alps - fix rushmore packet decoding X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f105e34a4e3ff073b0d96d5f91eb3c6e8dffaa4c;p=linux-beck.git Input: alps - fix rushmore packet decoding Signed-off-by: Yunkang Tang Signed-off-by: Hans de Goede Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c index fb15c64ffb95..e15daea56864 100644 --- a/drivers/input/mouse/alps.c +++ b/drivers/input/mouse/alps.c @@ -559,6 +559,9 @@ static void alps_decode_rushmore(struct alps_fields *f, unsigned char *p, { alps_decode_pinnacle(f, p, psmouse); + /* Rushmore's packet decode has a bit difference with Pinnacle's */ + f->is_mp = !!(p[5] & 0x40); + f->fingers = max((p[5] & 0x3), ((p[5] >> 2) & 0x3)) + 1; f->x_map |= (p[5] & 0x10) << 11; f->y_map |= (p[5] & 0x20) << 6; }