diff options
author | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 01:32:22 -0400 |
---|---|---|
committer | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 01:32:22 -0400 |
commit | 688897b0d4910e097f34c0e263d649cf2036eb45 (patch) | |
tree | 4b6eb217ca502d93c433ee721e3a62c5069eec65 /drivers/input/mouse | |
parent | 8d04ddb64c7bf62aec1102fddc5336a68bcaebe9 (diff) |
Input: logips2pp - ignore mice reporting model as 0
There are mice reporting to logitech's queries with model
of 0. Do not claim that these are Logitech mice.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/mouse')
-rw-r--r-- | drivers/input/mouse/logips2pp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/input/mouse/logips2pp.c b/drivers/input/mouse/logips2pp.c index d3ddea26b8ca..74a8ba7c71f8 100644 --- a/drivers/input/mouse/logips2pp.c +++ b/drivers/input/mouse/logips2pp.c | |||
@@ -338,12 +338,12 @@ int ps2pp_init(struct psmouse *psmouse, int set_properties) | |||
338 | param[1] = 0; | 338 | param[1] = 0; |
339 | ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO); | 339 | ps2_command(ps2dev, param, PSMOUSE_CMD_GETINFO); |
340 | 340 | ||
341 | if (!param[1]) | ||
342 | return -1; | ||
343 | |||
344 | model = ((param[0] >> 4) & 0x07) | ((param[0] << 3) & 0x78); | 341 | model = ((param[0] >> 4) & 0x07) | ((param[0] << 3) & 0x78); |
345 | buttons = param[1]; | 342 | buttons = param[1]; |
346 | 343 | ||
344 | if (!model || !buttons) | ||
345 | return -1; | ||
346 | |||
347 | if ((model_info = get_model_info(model)) != NULL) { | 347 | if ((model_info = get_model_info(model)) != NULL) { |
348 | 348 | ||
349 | /* | 349 | /* |