diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-07-09 15:32:56 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-07-09 15:33:35 -0400 |
commit | a66413fbc37994710d638aec3314f735a7ac0df5 (patch) | |
tree | 2c3608e65ce9090cbf83a8d8deaeb375e25e3207 /drivers/input/mouse/synaptics.h | |
parent | 28d5fd860f97f017573c4cd8f199bab867c50a11 (diff) |
Input: synaptics - set minimum coordinates as reported by firmware
Newer Synaptics firmware allows to query minimum coordinates reported by
the device, let's use this data.
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/mouse/synaptics.h')
-rw-r--r-- | drivers/input/mouse/synaptics.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/input/mouse/synaptics.h b/drivers/input/mouse/synaptics.h index b8025b0ee2bd..a4394e1f12a2 100644 --- a/drivers/input/mouse/synaptics.h +++ b/drivers/input/mouse/synaptics.h | |||
@@ -19,7 +19,8 @@ | |||
19 | #define SYN_QUE_RESOLUTION 0x08 | 19 | #define SYN_QUE_RESOLUTION 0x08 |
20 | #define SYN_QUE_EXT_CAPAB 0x09 | 20 | #define SYN_QUE_EXT_CAPAB 0x09 |
21 | #define SYN_QUE_EXT_CAPAB_0C 0x0c | 21 | #define SYN_QUE_EXT_CAPAB_0C 0x0c |
22 | #define SYN_QUE_EXT_DIMENSIONS 0x0d | 22 | #define SYN_QUE_EXT_MAX_COORDS 0x0d |
23 | #define SYN_QUE_EXT_MIN_COORDS 0x0f | ||
23 | 24 | ||
24 | /* synatics modes */ | 25 | /* synatics modes */ |
25 | #define SYN_BIT_ABSOLUTE_MODE (1 << 7) | 26 | #define SYN_BIT_ABSOLUTE_MODE (1 << 7) |
@@ -73,10 +74,12 @@ | |||
73 | * 2 0x04 reduced filtering firmware does less filtering on | 74 | * 2 0x04 reduced filtering firmware does less filtering on |
74 | * position data, driver should watch | 75 | * position data, driver should watch |
75 | * for noise. | 76 | * for noise. |
77 | * 2 0x20 report min query 0x0f gives min coord reported | ||
76 | */ | 78 | */ |
77 | #define SYN_CAP_CLICKPAD(ex0c) ((ex0c) & 0x100000) /* 1-button ClickPad */ | 79 | #define SYN_CAP_CLICKPAD(ex0c) ((ex0c) & 0x100000) /* 1-button ClickPad */ |
78 | #define SYN_CAP_CLICKPAD2BTN(ex0c) ((ex0c) & 0x000100) /* 2-button ClickPad */ | 80 | #define SYN_CAP_CLICKPAD2BTN(ex0c) ((ex0c) & 0x000100) /* 2-button ClickPad */ |
79 | #define SYN_CAP_MAX_DIMENSIONS(ex0c) ((ex0c) & 0x020000) | 81 | #define SYN_CAP_MAX_DIMENSIONS(ex0c) ((ex0c) & 0x020000) |
82 | #define SYN_CAP_MIN_DIMENSIONS(ex0c) ((ex0c) & 0x000200) | ||
80 | #define SYN_CAP_ADV_GESTURE(ex0c) ((ex0c) & 0x080000) | 83 | #define SYN_CAP_ADV_GESTURE(ex0c) ((ex0c) & 0x080000) |
81 | #define SYN_CAP_REDUCED_FILTERING(ex0c) ((ex0c) & 0x000400) | 84 | #define SYN_CAP_REDUCED_FILTERING(ex0c) ((ex0c) & 0x000400) |
82 | 85 | ||
@@ -134,7 +137,8 @@ struct synaptics_data { | |||
134 | unsigned long int ext_cap_0c; /* Ext Caps from 0x0c query */ | 137 | unsigned long int ext_cap_0c; /* Ext Caps from 0x0c query */ |
135 | unsigned long int identity; /* Identification */ | 138 | unsigned long int identity; /* Identification */ |
136 | unsigned int x_res, y_res; /* X/Y resolution in units/mm */ | 139 | unsigned int x_res, y_res; /* X/Y resolution in units/mm */ |
137 | unsigned int x_max, y_max; /* Max dimensions (from FW) */ | 140 | unsigned int x_max, y_max; /* Max coordinates (from FW) */ |
141 | unsigned int x_min, y_min; /* Min coordinates (from FW) */ | ||
138 | 142 | ||
139 | unsigned char pkt_type; /* packet type - old, new, etc */ | 143 | unsigned char pkt_type; /* packet type - old, new, etc */ |
140 | unsigned char mode; /* current mode byte */ | 144 | unsigned char mode; /* current mode byte */ |