aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/mouse/psmouse-base.c
diff options
context:
space:
mode:
authorMathias Gottschlag <mgottschlag@gmail.com>2014-12-29 12:26:35 -0500
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2014-12-29 12:51:37 -0500
commit05be1d079ec0b3691783e4384b1ada82149ff7d2 (patch)
treebd305e4dba7394c5eba6992f0f03e02b4812a438 /drivers/input/mouse/psmouse-base.c
parent5fafed3e5612e9f308d20dc94adf5fc3d4a1a2a8 (diff)
Input: psmouse - support for the FocalTech PS/2 protocol extensions
Most of the protocol for these touchpads has been reverse engineered. This commit adds a basic multitouch-capable driver. A lot of the protocol is still unknown. Especially, we don't know how to identify the device yet apart from the PNP ID. The previous workaround for these devices has been left in place in case the driver is not compiled into the kernel or in case some other device with the same PNP ID is not recognized by the driver yet still has the same problems with the device probing code. Signed-off-by: Mathias Gottschlag <mgottschlag@gmail.com> Reviewed-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.c32
1 files changed, 22 insertions, 10 deletions
diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c
index 26994f6a2b2a..4a9de33a9afd 100644
--- a/drivers/input/mouse/psmouse-base.c
+++ b/drivers/input/mouse/psmouse-base.c
@@ -725,16 +725,19 @@ static int psmouse_extensions(struct psmouse *psmouse,
725 725
726/* Always check for focaltech, this is safe as it uses pnp-id matching */ 726/* Always check for focaltech, this is safe as it uses pnp-id matching */
727 if (psmouse_do_detect(focaltech_detect, psmouse, set_properties) == 0) { 727 if (psmouse_do_detect(focaltech_detect, psmouse, set_properties) == 0) {
728 if (!set_properties || focaltech_init(psmouse) == 0) { 728 if (max_proto > PSMOUSE_IMEX) {
729 /* 729 if (!set_properties || focaltech_init(psmouse) == 0) {
730 * Not supported yet, use bare protocol. 730 if (focaltech_supported())
731 * Note that we need to also restrict 731 return PSMOUSE_FOCALTECH;
732 * psmouse_max_proto so that psmouse_initialize() 732 /*
733 * does not try to reset rate and resolution, 733 * Note that we need to also restrict
734 * because even that upsets the device. 734 * psmouse_max_proto so that psmouse_initialize()
735 */ 735 * does not try to reset rate and resolution,
736 psmouse_max_proto = PSMOUSE_PS2; 736 * because even that upsets the device.
737 return PSMOUSE_PS2; 737 */
738 psmouse_max_proto = PSMOUSE_PS2;
739 return PSMOUSE_PS2;
740 }
738 } 741 }
739 } 742 }
740 743
@@ -1063,6 +1066,15 @@ static const struct psmouse_protocol psmouse_protocols[] = {
1063 .alias = "cortps", 1066 .alias = "cortps",
1064 .detect = cortron_detect, 1067 .detect = cortron_detect,
1065 }, 1068 },
1069#ifdef CONFIG_MOUSE_PS2_FOCALTECH
1070 {
1071 .type = PSMOUSE_FOCALTECH,
1072 .name = "FocalTechPS/2",
1073 .alias = "focaltech",
1074 .detect = focaltech_detect,
1075 .init = focaltech_init,
1076 },
1077#endif
1066 { 1078 {
1067 .type = PSMOUSE_AUTO, 1079 .type = PSMOUSE_AUTO,
1068 .name = "auto", 1080 .name = "auto",