aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/mouse
diff options
context:
space:
mode:
authorDmitry Torokhov <dtor@insightbb.com>2007-04-12 01:30:41 -0400
committerDmitry Torokhov <dtor@insightbb.com>2007-04-12 01:30:41 -0400
commit887cc127233f34e833d074380f433a04de207563 (patch)
treee1c819dfc97feeade94a08b4482982a7be931ef4 /drivers/input/mouse
parent598972d4fb39c8a0826b396e45dc2a8c1dbe4f11 (diff)
Input: synaptics - export model bits
Encode synaptics model in psmouse->model so it will be exported via sysfs as input_dev->id.version and become visible for applications. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/mouse')
-rw-r--r--drivers/input/mouse/synaptics.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c
index e42a0a4345ac..c77788bf932d 100644
--- a/drivers/input/mouse/synaptics.c
+++ b/drivers/input/mouse/synaptics.c
@@ -655,6 +655,16 @@ int synaptics_init(struct psmouse *psmouse)
655 655
656 set_input_params(psmouse->dev, priv); 656 set_input_params(psmouse->dev, priv);
657 657
658 /*
659 * Encode touchpad model so that it can be used to set
660 * input device->id.version and be visible to userspace.
661 * Because version is __u16 we have to drop something.
662 * Hardware info bits seem to be good candidates as they
663 * are documented to be for Synaptics corp. internal use.
664 */
665 psmouse->model = ((priv->model_id & 0x00ff0000) >> 8) |
666 (priv->model_id & 0x000000ff);
667
658 psmouse->protocol_handler = synaptics_process_byte; 668 psmouse->protocol_handler = synaptics_process_byte;
659 psmouse->set_rate = synaptics_set_rate; 669 psmouse->set_rate = synaptics_set_rate;
660 psmouse->disconnect = synaptics_disconnect; 670 psmouse->disconnect = synaptics_disconnect;