History

Input: atmel_mxt_ts - Support for touchpad variant

This same driver can be used by atmel based touchscreens and touchpads (buttonpads). Platform data may specify a device is a touchpad using the is_tp flag. This will cause the driver to perform some touchpad specific initializations, such as: * register input device name "Atmel maXTouch Touchpad" instead of Touchscreen. * register BTN_LEFT & BTN_TOOL_* event types. * register axis resolution (as a fixed constant, for now) * register BUTTONPAD property * process GPIO buttons using reportid T19 Input event GPIO mapping is done by the platform data key_map array. key_map[x] should contain the KEY or BTN code to send when processing GPIOx from T19. To specify a GPIO as not an input source, populate with KEY_RESERVED, or 0.

Daniel Kurtz committed 13 years ago

Commit 22dfab71 parent 67a865a2 files · +67 −2Browse files

Showing the changes to include (1 of 2 files). Show all

Unified · Split

include/linux/i2c/atmel_mxt_ts.h+5−0
@@ -15,6 +15,9 @@ · 14 unmodified lines
1515
1616 #include <linux/types.h>
1717
18+/* For key_map array */
19+#define MXT_NUM_GPIO 4
20+
1821 /* Orient */
1922 #define MXT_NORMAL 0x0
2023 #define MXT_DIAGONAL 0x1
@@ -39,6 +42,8 @@ struct mxt_platform_data { · 18 unmodified lines
3942 unsigned int voltage;
4043 unsigned char orient;
4144 unsigned long irqflags;
45+ bool is_tp;
46+ const unsigned int key_map[MXT_NUM_GPIO];
4247 };
4348
4449 #endif /* __LINUX_ATMEL_MXT_TS_H */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t