diff options
author | Edgar (gimli) Hucek <gimli@dark-green.com> | 2010-11-09 11:38:42 -0500 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2010-11-15 08:18:36 -0500 |
commit | 6021afcf19d8c6f5db6d11cadcfb6a22d0c28a48 (patch) | |
tree | 0e41bbe4adcee84bc941f6724754d910188da96b /drivers/input | |
parent | a4bc6926d05b60bf70aab2db2c6715e15118cbdc (diff) |
input: bcm5974: Add support for MacBookAir3
This patch adds support for the MacBookAir3,1 and MacBookAir3,2
models.
[rydberg@euromail.se: touchpad range calibration]
Cc: stable@kernel.org
Signed-off-by: Edgar (gimli) Hucek <gimli@dark-green.com>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/mouse/bcm5974.c | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/drivers/input/mouse/bcm5974.c b/drivers/input/mouse/bcm5974.c index b95231763911..ee82851afe3e 100644 --- a/drivers/input/mouse/bcm5974.c +++ b/drivers/input/mouse/bcm5974.c | |||
@@ -55,6 +55,14 @@ | |||
55 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI 0x0236 | 55 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI 0x0236 |
56 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_ISO 0x0237 | 56 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_ISO 0x0237 |
57 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_JIS 0x0238 | 57 | #define USB_DEVICE_ID_APPLE_WELLSPRING3_JIS 0x0238 |
58 | /* MacbookAir3,2 (unibody), aka wellspring5 */ | ||
59 | #define USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI 0x023f | ||
60 | #define USB_DEVICE_ID_APPLE_WELLSPRING4_ISO 0x0240 | ||
61 | #define USB_DEVICE_ID_APPLE_WELLSPRING4_JIS 0x0241 | ||
62 | /* MacbookAir3,1 (unibody), aka wellspring4 */ | ||
63 | #define USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI 0x0242 | ||
64 | #define USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO 0x0243 | ||
65 | #define USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS 0x0244 | ||
58 | 66 | ||
59 | #define BCM5974_DEVICE(prod) { \ | 67 | #define BCM5974_DEVICE(prod) { \ |
60 | .match_flags = (USB_DEVICE_ID_MATCH_DEVICE | \ | 68 | .match_flags = (USB_DEVICE_ID_MATCH_DEVICE | \ |
@@ -80,6 +88,14 @@ static const struct usb_device_id bcm5974_table[] = { | |||
80 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI), | 88 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI), |
81 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ISO), | 89 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ISO), |
82 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_JIS), | 90 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_JIS), |
91 | /* MacbookAir3,2 */ | ||
92 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI), | ||
93 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ISO), | ||
94 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_JIS), | ||
95 | /* MacbookAir3,1 */ | ||
96 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI), | ||
97 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO), | ||
98 | BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS), | ||
83 | /* Terminating entry */ | 99 | /* Terminating entry */ |
84 | {} | 100 | {} |
85 | }; | 101 | }; |
@@ -234,6 +250,30 @@ static const struct bcm5974_config bcm5974_config_table[] = { | |||
234 | { DIM_X, DIM_X / SN_COORD, -4460, 5166 }, | 250 | { DIM_X, DIM_X / SN_COORD, -4460, 5166 }, |
235 | { DIM_Y, DIM_Y / SN_COORD, -75, 6700 } | 251 | { DIM_Y, DIM_Y / SN_COORD, -75, 6700 } |
236 | }, | 252 | }, |
253 | { | ||
254 | USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI, | ||
255 | USB_DEVICE_ID_APPLE_WELLSPRING4_ISO, | ||
256 | USB_DEVICE_ID_APPLE_WELLSPRING4_JIS, | ||
257 | HAS_INTEGRATED_BUTTON, | ||
258 | 0x84, sizeof(struct bt_data), | ||
259 | 0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS, | ||
260 | { DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 }, | ||
261 | { DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 }, | ||
262 | { DIM_X, DIM_X / SN_COORD, -4620, 5140 }, | ||
263 | { DIM_Y, DIM_Y / SN_COORD, -150, 6600 } | ||
264 | }, | ||
265 | { | ||
266 | USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI, | ||
267 | USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO, | ||
268 | USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS, | ||
269 | HAS_INTEGRATED_BUTTON, | ||
270 | 0x84, sizeof(struct bt_data), | ||
271 | 0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS, | ||
272 | { DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 }, | ||
273 | { DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 }, | ||
274 | { DIM_X, DIM_X / SN_COORD, -4616, 5112 }, | ||
275 | { DIM_Y, DIM_Y / SN_COORD, -142, 5234 } | ||
276 | }, | ||
237 | {} | 277 | {} |
238 | }; | 278 | }; |
239 | 279 | ||