diff options
author | Kevin Cernekee <cernekee@gmail.com> | 2013-02-14 01:24:22 -0500 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2013-02-14 12:18:16 -0500 |
commit | 56fd340ebb533cb45c5eaf350cf889c43c5911e6 (patch) | |
tree | 1a0e6dc72346515e85d5d24747c7d2aff7c5dddc | |
parent | f673ceb11b880e8535476326612e54c3e0cace5b (diff) |
Input: ALPS - fix command mode check
Pinnacle class devices should return "88 07 xx" or "88 08 xx" when
entering command mode. If either the first byte or the second byte is
invalid, return an error.
Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
Tested-by: Dave Turvene <dturvene@dahetral.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-rw-r--r-- | drivers/input/mouse/alps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c index eafeae279356..bfc193806fc1 100644 --- a/drivers/input/mouse/alps.c +++ b/drivers/input/mouse/alps.c | |||
@@ -983,7 +983,7 @@ static int alps_enter_command_mode(struct psmouse *psmouse, | |||
983 | return -1; | 983 | return -1; |
984 | } | 984 | } |
985 | 985 | ||
986 | if (param[0] != 0x88 && param[1] != 0x07) { | 986 | if (param[0] != 0x88 || (param[1] != 0x07 && param[1] != 0x08)) { |
987 | psmouse_dbg(psmouse, | 987 | psmouse_dbg(psmouse, |
988 | "unknown response while entering command mode\n"); | 988 | "unknown response while entering command mode\n"); |
989 | return -1; | 989 | return -1; |