diff options
author | Hans de Goede <hdegoede@redhat.com> | 2014-09-12 17:24:47 -0700 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-09-15 14:30:46 -0700 |
commit | 3ace3686f198e656624d7ca2984d053e65f6e09d (patch) | |
tree | 45ca6b9bf62cf53dafa0325ae26eabdb6de2952a /drivers/input/mouse/psmouse-base.c | |
parent | 2c75ada6250990ea859b0b5498cb0b7c2823a9d7 (diff) | |
download | blackbird-op-linux-3ace3686f198e656624d7ca2984d053e65f6e09d.tar.gz blackbird-op-linux-3ace3686f198e656624d7ca2984d053e65f6e09d.zip |
Input: psmouse - add support for detecting FocalTech PS/2 touchpads
The Asus X450 and X550 laptops use a PS/2 touchpad from a new
manufacturer called FocalTech:
https://bugzilla.kernel.org/show_bug.cgi?id=77391
https://bugzilla.redhat.com/show_bug.cgi?id=1110011
The protocol for these devices is not known at this time, but even
without knowing the protocol they need some special handling. They get
upset by some of our other PS/2 device probing, and once upset generate
random mouse events making things unusable even with an external mouse.
This patch adds detection of these devices based on their pnp ids, and
when they are detected, treats them as a bare ps/2 mouse. Doing things
this way they at least work in their ps/2 mouse emulation mode.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/mouse/psmouse-base.c')
-rw-r--r-- | drivers/input/mouse/psmouse-base.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c index bc1bc2653f15..3ab941d425ae 100644 --- a/drivers/input/mouse/psmouse-base.c +++ b/drivers/input/mouse/psmouse-base.c @@ -35,6 +35,7 @@ #include "elantech.h" #include "sentelic.h" #include "cypress_ps2.h" +#include "focaltech.h" #define DRIVER_DESC "PS/2 mouse driver" @@ -720,6 +721,21 @@ static int psmouse_extensions(struct psmouse *psmouse, { bool synaptics_hardware = false; +/* Always check for focaltech, this is safe as it uses pnp-id matching */ + if (psmouse_do_detect(focaltech_detect, psmouse, set_properties) == 0) { + if (!set_properties || focaltech_init(psmouse) == 0) { + /* + * Not supported yet, use bare protocol. + * Note that we need to also restrict + * psmouse_max_proto so that psmouse_initialize() + * does not try to reset rate and resolution, + * because even that upsets the device. + */ + psmouse_max_proto = PSMOUSE_PS2; + return PSMOUSE_PS2; + } + } + /* * We always check for lifebook because it does not disturb mouse * (it only checks DMI information). |