diff options
Diffstat (limited to 'drivers/input/mouse')
-rw-r--r-- | drivers/input/mouse/alps.c | 29 | ||||
-rw-r--r-- | drivers/input/mouse/logips2pp.c | 2 | ||||
-rw-r--r-- | drivers/input/mouse/psmouse-base.c | 2 | ||||
-rw-r--r-- | drivers/input/mouse/synaptics.c | 14 |
4 files changed, 22 insertions, 25 deletions
diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c index a12e98158a75..0d68e5e0182a 100644 --- a/drivers/input/mouse/alps.c +++ b/drivers/input/mouse/alps.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * ALPS touchpad PS/2 mouse driver | 2 | * ALPS touchpad PS/2 mouse driver |
3 | * | 3 | * |
4 | * Copyright (c) 2003 Neil Brown <neilb@cse.unsw.edu.au> | 4 | * Copyright (c) 2003 Neil Brown <neilb@cse.unsw.edu.au> |
5 | * Copyright (c) 2003 Peter Osterlund <petero2@telia.com> | 5 | * Copyright (c) 2003-2005 Peter Osterlund <petero2@telia.com> |
6 | * Copyright (c) 2004 Dmitry Torokhov <dtor@mail.ru> | 6 | * Copyright (c) 2004 Dmitry Torokhov <dtor@mail.ru> |
7 | * Copyright (c) 2005 Vojtech Pavlik <vojtech@suse.cz> | 7 | * Copyright (c) 2005 Vojtech Pavlik <vojtech@suse.cz> |
8 | * | 8 | * |
@@ -350,7 +350,6 @@ static int alps_tap_mode(struct psmouse *psmouse, int enable) | |||
350 | static int alps_reconnect(struct psmouse *psmouse) | 350 | static int alps_reconnect(struct psmouse *psmouse) |
351 | { | 351 | { |
352 | struct alps_data *priv = psmouse->private; | 352 | struct alps_data *priv = psmouse->private; |
353 | unsigned char param[4]; | ||
354 | int version; | 353 | int version; |
355 | 354 | ||
356 | psmouse_reset(psmouse); | 355 | psmouse_reset(psmouse); |
@@ -358,21 +357,20 @@ static int alps_reconnect(struct psmouse *psmouse) | |||
358 | if (!(priv->i = alps_get_model(psmouse, &version))) | 357 | if (!(priv->i = alps_get_model(psmouse, &version))) |
359 | return -1; | 358 | return -1; |
360 | 359 | ||
361 | if (priv->i->flags & ALPS_PASS && alps_passthrough_mode(psmouse, 1)) | 360 | if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 1)) |
362 | return -1; | 361 | return -1; |
363 | 362 | ||
364 | if (alps_get_status(psmouse, param)) | 363 | if (alps_tap_mode(psmouse, 1)) { |
364 | printk(KERN_WARNING "alps.c: Failed to reenable hardware tapping\n"); | ||
365 | return -1; | 365 | return -1; |
366 | 366 | } | |
367 | if (!(param[0] & 0x04)) | ||
368 | alps_tap_mode(psmouse, 1); | ||
369 | 367 | ||
370 | if (alps_absolute_mode(psmouse)) { | 368 | if (alps_absolute_mode(psmouse)) { |
371 | printk(KERN_ERR "alps.c: Failed to enable absolute mode\n"); | 369 | printk(KERN_ERR "alps.c: Failed to reenable absolute mode\n"); |
372 | return -1; | 370 | return -1; |
373 | } | 371 | } |
374 | 372 | ||
375 | if (priv->i->flags == ALPS_PASS && alps_passthrough_mode(psmouse, 0)) | 373 | if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 0)) |
376 | return -1; | 374 | return -1; |
377 | 375 | ||
378 | return 0; | 376 | return 0; |
@@ -389,7 +387,6 @@ static void alps_disconnect(struct psmouse *psmouse) | |||
389 | int alps_init(struct psmouse *psmouse) | 387 | int alps_init(struct psmouse *psmouse) |
390 | { | 388 | { |
391 | struct alps_data *priv; | 389 | struct alps_data *priv; |
392 | unsigned char param[4]; | ||
393 | int version; | 390 | int version; |
394 | 391 | ||
395 | psmouse->private = priv = kmalloc(sizeof(struct alps_data), GFP_KERNEL); | 392 | psmouse->private = priv = kmalloc(sizeof(struct alps_data), GFP_KERNEL); |
@@ -403,16 +400,8 @@ int alps_init(struct psmouse *psmouse) | |||
403 | if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 1)) | 400 | if ((priv->i->flags & ALPS_PASS) && alps_passthrough_mode(psmouse, 1)) |
404 | goto init_fail; | 401 | goto init_fail; |
405 | 402 | ||
406 | if (alps_get_status(psmouse, param)) { | 403 | if (alps_tap_mode(psmouse, 1)) |
407 | printk(KERN_ERR "alps.c: touchpad status report request failed\n"); | 404 | printk(KERN_WARNING "alps.c: Failed to enable hardware tapping\n"); |
408 | goto init_fail; | ||
409 | } | ||
410 | |||
411 | if (param[0] & 0x04) { | ||
412 | printk(KERN_INFO "alps.c: Enabling hardware tapping\n"); | ||
413 | if (alps_tap_mode(psmouse, 1)) | ||
414 | printk(KERN_WARNING "alps.c: Failed to enable hardware tapping\n"); | ||
415 | } | ||
416 | 405 | ||
417 | if (alps_absolute_mode(psmouse)) { | 406 | if (alps_absolute_mode(psmouse)) { |
418 | printk(KERN_ERR "alps.c: Failed to enable absolute mode\n"); | 407 | printk(KERN_ERR "alps.c: Failed to enable absolute mode\n"); |
diff --git a/drivers/input/mouse/logips2pp.c b/drivers/input/mouse/logips2pp.c index 5ab1bd7d529d..48d2b20d2642 100644 --- a/drivers/input/mouse/logips2pp.c +++ b/drivers/input/mouse/logips2pp.c | |||
@@ -385,8 +385,6 @@ int ps2pp_init(struct psmouse *psmouse, int set_properties) | |||
385 | 385 | ||
386 | if (buttons < 3) | 386 | if (buttons < 3) |
387 | clear_bit(BTN_MIDDLE, psmouse->dev.keybit); | 387 | clear_bit(BTN_MIDDLE, psmouse->dev.keybit); |
388 | if (buttons < 2) | ||
389 | clear_bit(BTN_RIGHT, psmouse->dev.keybit); | ||
390 | 388 | ||
391 | if (model_info) | 389 | if (model_info) |
392 | ps2pp_set_model_properties(psmouse, model_info, use_ps2pp); | 390 | ps2pp_set_model_properties(psmouse, model_info, use_ps2pp); |
diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c index 19785a6c5abd..2bb2fe78bdca 100644 --- a/drivers/input/mouse/psmouse-base.c +++ b/drivers/input/mouse/psmouse-base.c | |||
@@ -344,6 +344,7 @@ static int intellimouse_detect(struct psmouse *psmouse, int set_properties) | |||
344 | return -1; | 344 | return -1; |
345 | 345 | ||
346 | if (set_properties) { | 346 | if (set_properties) { |
347 | set_bit(BTN_MIDDLE, psmouse->dev.keybit); | ||
347 | set_bit(REL_WHEEL, psmouse->dev.relbit); | 348 | set_bit(REL_WHEEL, psmouse->dev.relbit); |
348 | 349 | ||
349 | if (!psmouse->vendor) psmouse->vendor = "Generic"; | 350 | if (!psmouse->vendor) psmouse->vendor = "Generic"; |
@@ -376,6 +377,7 @@ static int im_explorer_detect(struct psmouse *psmouse, int set_properties) | |||
376 | return -1; | 377 | return -1; |
377 | 378 | ||
378 | if (set_properties) { | 379 | if (set_properties) { |
380 | set_bit(BTN_MIDDLE, psmouse->dev.keybit); | ||
379 | set_bit(REL_WHEEL, psmouse->dev.relbit); | 381 | set_bit(REL_WHEEL, psmouse->dev.relbit); |
380 | set_bit(BTN_SIDE, psmouse->dev.keybit); | 382 | set_bit(BTN_SIDE, psmouse->dev.keybit); |
381 | set_bit(BTN_EXTRA, psmouse->dev.keybit); | 383 | set_bit(BTN_EXTRA, psmouse->dev.keybit); |
diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c index 36c721227b68..029309422409 100644 --- a/drivers/input/mouse/synaptics.c +++ b/drivers/input/mouse/synaptics.c | |||
@@ -219,7 +219,7 @@ static void synaptics_pass_pt_packet(struct serio *ptport, unsigned char *packet | |||
219 | serio_interrupt(ptport, packet[1], 0, NULL); | 219 | serio_interrupt(ptport, packet[1], 0, NULL); |
220 | serio_interrupt(ptport, packet[4], 0, NULL); | 220 | serio_interrupt(ptport, packet[4], 0, NULL); |
221 | serio_interrupt(ptport, packet[5], 0, NULL); | 221 | serio_interrupt(ptport, packet[5], 0, NULL); |
222 | if (child->type >= PSMOUSE_GENPS) | 222 | if (child->pktsize == 4) |
223 | serio_interrupt(ptport, packet[2], 0, NULL); | 223 | serio_interrupt(ptport, packet[2], 0, NULL); |
224 | } else | 224 | } else |
225 | serio_interrupt(ptport, packet[1], 0, NULL); | 225 | serio_interrupt(ptport, packet[1], 0, NULL); |
@@ -233,7 +233,7 @@ static void synaptics_pt_activate(struct psmouse *psmouse) | |||
233 | 233 | ||
234 | /* adjust the touchpad to child's choice of protocol */ | 234 | /* adjust the touchpad to child's choice of protocol */ |
235 | if (child) { | 235 | if (child) { |
236 | if (child->type >= PSMOUSE_GENPS) | 236 | if (child->pktsize == 4) |
237 | priv->mode |= SYN_BIT_FOUR_BYTE_CLIENT; | 237 | priv->mode |= SYN_BIT_FOUR_BYTE_CLIENT; |
238 | else | 238 | else |
239 | priv->mode &= ~SYN_BIT_FOUR_BYTE_CLIENT; | 239 | priv->mode &= ~SYN_BIT_FOUR_BYTE_CLIENT; |
@@ -608,6 +608,13 @@ static struct dmi_system_id toshiba_dmi_table[] = { | |||
608 | DMI_MATCH(DMI_PRODUCT_NAME , "Satellite"), | 608 | DMI_MATCH(DMI_PRODUCT_NAME , "Satellite"), |
609 | }, | 609 | }, |
610 | }, | 610 | }, |
611 | { | ||
612 | .ident = "Toshiba Dynabook", | ||
613 | .matches = { | ||
614 | DMI_MATCH(DMI_SYS_VENDOR, "TOSHIBA"), | ||
615 | DMI_MATCH(DMI_PRODUCT_NAME , "dynabook"), | ||
616 | }, | ||
617 | }, | ||
611 | { } | 618 | { } |
612 | }; | 619 | }; |
613 | #endif | 620 | #endif |
@@ -656,7 +663,8 @@ int synaptics_init(struct psmouse *psmouse) | |||
656 | * thye same as rate of standard PS/2 mouse. | 663 | * thye same as rate of standard PS/2 mouse. |
657 | */ | 664 | */ |
658 | if (psmouse->rate >= 80 && dmi_check_system(toshiba_dmi_table)) { | 665 | if (psmouse->rate >= 80 && dmi_check_system(toshiba_dmi_table)) { |
659 | printk(KERN_INFO "synaptics: Toshiba Satellite detected, limiting rate to 40pps.\n"); | 666 | printk(KERN_INFO "synaptics: Toshiba %s detected, limiting rate to 40pps.\n", |
667 | dmi_get_system_info(DMI_PRODUCT_NAME)); | ||
660 | psmouse->rate = 40; | 668 | psmouse->rate = 40; |
661 | } | 669 | } |
662 | #endif | 670 | #endif |