diff options
Diffstat (limited to 'include/linux/i2c/adp5588.h')
-rw-r--r-- | include/linux/i2c/adp5588.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/include/linux/i2c/adp5588.h b/include/linux/i2c/adp5588.h index 02c9af374741..269181b8f623 100644 --- a/include/linux/i2c/adp5588.h +++ b/include/linux/i2c/adp5588.h | |||
@@ -78,6 +78,40 @@ | |||
78 | 78 | ||
79 | #define ADP5588_KEYMAPSIZE 80 | 79 | #define ADP5588_KEYMAPSIZE 80 |
80 | 80 | ||
81 | #define GPI_PIN_ROW0 97 | ||
82 | #define GPI_PIN_ROW1 98 | ||
83 | #define GPI_PIN_ROW2 99 | ||
84 | #define GPI_PIN_ROW3 100 | ||
85 | #define GPI_PIN_ROW4 101 | ||
86 | #define GPI_PIN_ROW5 102 | ||
87 | #define GPI_PIN_ROW6 103 | ||
88 | #define GPI_PIN_ROW7 104 | ||
89 | #define GPI_PIN_COL0 105 | ||
90 | #define GPI_PIN_COL1 106 | ||
91 | #define GPI_PIN_COL2 107 | ||
92 | #define GPI_PIN_COL3 108 | ||
93 | #define GPI_PIN_COL4 109 | ||
94 | #define GPI_PIN_COL5 110 | ||
95 | #define GPI_PIN_COL6 111 | ||
96 | #define GPI_PIN_COL7 112 | ||
97 | #define GPI_PIN_COL8 113 | ||
98 | #define GPI_PIN_COL9 114 | ||
99 | |||
100 | #define GPI_PIN_ROW_BASE GPI_PIN_ROW0 | ||
101 | #define GPI_PIN_ROW_END GPI_PIN_ROW7 | ||
102 | #define GPI_PIN_COL_BASE GPI_PIN_COL0 | ||
103 | #define GPI_PIN_COL_END GPI_PIN_COL9 | ||
104 | |||
105 | #define GPI_PIN_BASE GPI_PIN_ROW_BASE | ||
106 | #define GPI_PIN_END GPI_PIN_COL_END | ||
107 | |||
108 | #define ADP5588_GPIMAPSIZE_MAX (GPI_PIN_END - GPI_PIN_BASE + 1) | ||
109 | |||
110 | struct adp5588_gpi_map { | ||
111 | unsigned short pin; | ||
112 | unsigned short sw_evt; | ||
113 | }; | ||
114 | |||
81 | struct adp5588_kpad_platform_data { | 115 | struct adp5588_kpad_platform_data { |
82 | int rows; /* Number of rows */ | 116 | int rows; /* Number of rows */ |
83 | int cols; /* Number of columns */ | 117 | int cols; /* Number of columns */ |
@@ -87,6 +121,9 @@ struct adp5588_kpad_platform_data { | |||
87 | unsigned en_keylock:1; /* Enable Key Lock feature */ | 121 | unsigned en_keylock:1; /* Enable Key Lock feature */ |
88 | unsigned short unlock_key1; /* Unlock Key 1 */ | 122 | unsigned short unlock_key1; /* Unlock Key 1 */ |
89 | unsigned short unlock_key2; /* Unlock Key 2 */ | 123 | unsigned short unlock_key2; /* Unlock Key 2 */ |
124 | const struct adp5588_gpi_map *gpimap; | ||
125 | unsigned short gpimapsize; | ||
126 | const struct adp5588_gpio_platform_data *gpio_data; | ||
90 | }; | 127 | }; |
91 | 128 | ||
92 | struct adp5588_gpio_platform_data { | 129 | struct adp5588_gpio_platform_data { |