diff options
Diffstat (limited to 'arch/arm/mach-pxa/em-x270.c')
-rw-r--r-- | arch/arm/mach-pxa/em-x270.c | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/arch/arm/mach-pxa/em-x270.c b/arch/arm/mach-pxa/em-x270.c index 446563a7d1ad..f6726bb4eb95 100644 --- a/arch/arm/mach-pxa/em-x270.c +++ b/arch/arm/mach-pxa/em-x270.c | |||
@@ -833,21 +833,25 @@ static inline void em_x270_init_ac97(void) {} | |||
833 | #endif | 833 | #endif |
834 | 834 | ||
835 | #if defined(CONFIG_KEYBOARD_PXA27x) || defined(CONFIG_KEYBOARD_PXA27x_MODULE) | 835 | #if defined(CONFIG_KEYBOARD_PXA27x) || defined(CONFIG_KEYBOARD_PXA27x_MODULE) |
836 | static unsigned int em_x270_module_matrix_keys[] = { | 836 | static const unsigned int em_x270_module_matrix_keys[] = { |
837 | KEY(0, 0, KEY_A), KEY(1, 0, KEY_UP), KEY(2, 1, KEY_B), | 837 | KEY(0, 0, KEY_A), KEY(1, 0, KEY_UP), KEY(2, 1, KEY_B), |
838 | KEY(0, 2, KEY_LEFT), KEY(1, 1, KEY_ENTER), KEY(2, 0, KEY_RIGHT), | 838 | KEY(0, 2, KEY_LEFT), KEY(1, 1, KEY_ENTER), KEY(2, 0, KEY_RIGHT), |
839 | KEY(0, 1, KEY_C), KEY(1, 2, KEY_DOWN), KEY(2, 2, KEY_D), | 839 | KEY(0, 1, KEY_C), KEY(1, 2, KEY_DOWN), KEY(2, 2, KEY_D), |
840 | }; | 840 | }; |
841 | 841 | ||
842 | static struct matrix_keymap_data em_x270_matrix_keymap_data = { | ||
843 | .keymap = em_x270_module_matrix_keys, | ||
844 | .keymap_size = ARRAY_SIZE(em_x270_module_matrix_keys), | ||
845 | }; | ||
846 | |||
842 | struct pxa27x_keypad_platform_data em_x270_module_keypad_info = { | 847 | struct pxa27x_keypad_platform_data em_x270_module_keypad_info = { |
843 | /* code map for the matrix keys */ | 848 | /* code map for the matrix keys */ |
844 | .matrix_key_rows = 3, | 849 | .matrix_key_rows = 3, |
845 | .matrix_key_cols = 3, | 850 | .matrix_key_cols = 3, |
846 | .matrix_key_map = em_x270_module_matrix_keys, | 851 | .matrix_keymap_data = &em_x270_matrix_keymap_data, |
847 | .matrix_key_map_size = ARRAY_SIZE(em_x270_module_matrix_keys), | ||
848 | }; | 852 | }; |
849 | 853 | ||
850 | static unsigned int em_x270_exeda_matrix_keys[] = { | 854 | static const unsigned int em_x270_exeda_matrix_keys[] = { |
851 | KEY(0, 0, KEY_RIGHTSHIFT), KEY(0, 1, KEY_RIGHTCTRL), | 855 | KEY(0, 0, KEY_RIGHTSHIFT), KEY(0, 1, KEY_RIGHTCTRL), |
852 | KEY(0, 2, KEY_RIGHTALT), KEY(0, 3, KEY_SPACE), | 856 | KEY(0, 2, KEY_RIGHTALT), KEY(0, 3, KEY_SPACE), |
853 | KEY(0, 4, KEY_LEFTALT), KEY(0, 5, KEY_LEFTCTRL), | 857 | KEY(0, 4, KEY_LEFTALT), KEY(0, 5, KEY_LEFTCTRL), |
@@ -889,12 +893,16 @@ static unsigned int em_x270_exeda_matrix_keys[] = { | |||
889 | KEY(7, 6, 0), KEY(7, 7, 0), | 893 | KEY(7, 6, 0), KEY(7, 7, 0), |
890 | }; | 894 | }; |
891 | 895 | ||
896 | static struct matrix_keymap_data em_x270_exeda_matrix_keymap_data = { | ||
897 | .keymap = em_x270_exeda_matrix_keys, | ||
898 | .keymap_size = ARRAY_SIZE(em_x270_exeda_matrix_keys), | ||
899 | }; | ||
900 | |||
892 | struct pxa27x_keypad_platform_data em_x270_exeda_keypad_info = { | 901 | struct pxa27x_keypad_platform_data em_x270_exeda_keypad_info = { |
893 | /* code map for the matrix keys */ | 902 | /* code map for the matrix keys */ |
894 | .matrix_key_rows = 8, | 903 | .matrix_key_rows = 8, |
895 | .matrix_key_cols = 8, | 904 | .matrix_key_cols = 8, |
896 | .matrix_key_map = em_x270_exeda_matrix_keys, | 905 | .matrix_keymap_data = &em_x270_exeda_matrix_keymap_data, |
897 | .matrix_key_map_size = ARRAY_SIZE(em_x270_exeda_matrix_keys), | ||
898 | }; | 906 | }; |
899 | 907 | ||
900 | static void __init em_x270_init_keypad(void) | 908 | static void __init em_x270_init_keypad(void) |