summaryrefslogtreecommitdiff
path: root/arch/arm/mach-pxa/littleton.c
diff options
context:
space:
mode:
authorChao Xie <chao.xie@marvell.com>2013-05-06 07:24:58 +0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2013-06-19 09:56:51 +0400
commit0a085a9482fa51efb58c9d351ea98e83c5df93fc (patch)
tree411592ae841ea8b18dce07a7e4bce3fce30fcadc /arch/arm/mach-pxa/littleton.c
parent483180281f0ac60d1138710eb21f4b9961901294 (diff)
downloadlinux-0a085a9482fa51efb58c9d351ea98e83c5df93fc.tar.xz
Input: pxa27x-keypad - use matrix_keymap for matrix keys
pxa27x-keypad includes matrix keys. Make use of matrix_keymap for the matrix keys. Signed-off-by: Chao Xie <chao.xie@marvell.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'arch/arm/mach-pxa/littleton.c')
-rw-r--r--arch/arm/mach-pxa/littleton.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/arch/arm/mach-pxa/littleton.c b/arch/arm/mach-pxa/littleton.c
index e848c4607baf..5d665588c7eb 100644
--- a/arch/arm/mach-pxa/littleton.c
+++ b/arch/arm/mach-pxa/littleton.c
@@ -222,7 +222,7 @@ static inline void littleton_init_spi(void) {}
#endif
#if defined(CONFIG_KEYBOARD_PXA27x) || defined(CONFIG_KEYBOARD_PXA27x_MODULE)
-static unsigned int littleton_matrix_key_map[] = {
+static const unsigned int littleton_matrix_key_map[] = {
/* KEY(row, col, key_code) */
KEY(1, 3, KEY_0), KEY(0, 0, KEY_1), KEY(1, 0, KEY_2), KEY(2, 0, KEY_3),
KEY(0, 1, KEY_4), KEY(1, 1, KEY_5), KEY(2, 1, KEY_6), KEY(0, 2, KEY_7),
@@ -249,11 +249,15 @@ static unsigned int littleton_matrix_key_map[] = {
KEY(3, 1, KEY_F23), /* soft2 */
};
+static struct matrix_keymap_data littleton_matrix_keymap_data = {
+ .keymap = littleton_matrix_key_map,
+ .keymap_size = ARRAY_SIZE(littleton_matrix_key_map),
+};
+
static struct pxa27x_keypad_platform_data littleton_keypad_info = {
.matrix_key_rows = 6,
.matrix_key_cols = 5,
- .matrix_key_map = littleton_matrix_key_map,
- .matrix_key_map_size = ARRAY_SIZE(littleton_matrix_key_map),
+ .matrix_keymap_data = &littleton_matrix_keymap_data,
.enable_rotary0 = 1,
.rotary0_up_key = KEY_UP,