summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Lauer <mickey@vanille-media.de>2006-06-09 01:28:11 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2006-06-09 01:28:11 +0000
commite033074b869f3856d69263bc43c5dd6998dcca99 (patch)
treec054e0a9b92cea6e157e876281a4e8ebc9f9201d
parent75948a3747e5199d47c4141205919672d02c375a (diff)
linux-ezx: fix e680 keypad properly, drop HACK patch
-rw-r--r--packages/linux/linux-ezx/e680-fix-keypad.patch150
-rw-r--r--packages/linux/linux-ezx/e680-keypad-compile-HACK.patch42
-rw-r--r--packages/linux/linux-ezx/pxakbd-fix-directkeys.patch15
-rw-r--r--packages/linux/linux-ezx_2.6.16.13.bb5
4 files changed, 168 insertions, 44 deletions
diff --git a/packages/linux/linux-ezx/e680-fix-keypad.patch b/packages/linux/linux-ezx/e680-fix-keypad.patch
new file mode 100644
index 0000000000..b40283f332
--- /dev/null
+++ b/packages/linux/linux-ezx/e680-fix-keypad.patch
@@ -0,0 +1,150 @@
+
+#
+# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
+#
+
+--- linux-2.6.16/arch/arm/mach-pxa/ezx.c~e680-fix-keypad 2006-06-09 01:55:06.000000000 +0200
++++ linux-2.6.16/arch/arm/mach-pxa/ezx.c 2006-06-09 03:09:26.000000000 +0200
+@@ -341,71 +341,25 @@
+ };
+ #endif
+
+-/* keyboard */
+-
+-#if defined(CONFIG_PXA_EZX_V700)
+-#error "kbd matrix still needs to be converted to new row/col layout"
+-static unsigned char ezx_keycode[] = {
+- /* col 0 */
+- KEY_UP, KEY_DOWN, KEY_LEFT, KEY_RIGHT,
+- KEYPAD_POUND, KEY_0, KEY_9, 0,
+- /* col 1 */
+- KEY_2, KEY_4, KEY_6, KEY_8,
+- KEY_7, KEYPAD_SLEFT, KEYPAD_SRIGHT, 0,
+- /* col 2 */
+- KEY_MENU, KEY_1, KEY_3, KEY_5,
+- KEY_KPASTERISK, KEY_VOLUMEUP, KEY_VOLUMEDOWN, 0,
+- /* col 3 */
+- KEY_CAMERA, KEYPAD_CLEAR, KEYPAD_CARRIER, KEYPAD_ACTIVATE,
+- KEYPAD_SEND, KEYPAD_SMART, KEYPAD_VAVR, 0,
+-};
+-static unsigned char ezx_direct_keycode[] = {
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+-};
+-#elif defined(CONFIG_PXA_EZX_E680_P4A)
+-#error "kbd matrix still needs to be converted to new row/col layout"
+-static unsigned char ezx_keycode[] = {
+- /* col 0 */
+- KEY_UP, KEY_DOWN, KEY_LEFT, 0, 0, 0, 0, 0,
+- /* col 1 */
+- KEY_RIGHT, KEY_CENTER, KEY_HOME, 0, 0, 0, 0, 0,
+- /* col 2 */
+- KEYPAD_GAME_R, 0, KEYPAD_GAME_L, 0, 0, 0, 0, 0,
+- /* col 3 */
+- KEY_A, KEY_B, 0, 0, 0, 0, 0, 0,
+-};
+-static unsigned char ezx_direct_keycode[] = {
+- KEY_CAMERA,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEY_POWER,
+- KEYPAD_NONE,
+-};
+-#elif defined(CONFIG_PXA_EZX_E680)
+-#error "kbd matrix still needs to be converted to new row/col layout"
++/*
++ * PXA Keyboard
++ */
++#if defined(CONFIG_PXA_EZX_E680)
+ static unsigned char ezx_keycode[] = {
+- /* col 0 */
+- KEY_UP, KEY_DOWN, 0, 0, 0, 0, 0, 0,
+- /* col 1 */
+- KEY_RIGHT, KEY_LEFT, 0, 0, 0, 0, 0, 0,
+- /* col 2 */
+- 0, KEYPAD_GAME_R, 0, 0, 0, 0, 0, 0,
+- /* col 3 */
+- KEYPAD_HOME, KEYPAD_GAME_L, KEYPAD_CENTER, 0, 0, 0, 0, 0,
++ /* row 0 */
++ KEY_UP, KEY_RIGHT, 0, KEY_PHONE,
++ /* row 1 */
++ KEY_DOWN, KEY_LEFT, KEY_VOLUMEUP, KEY_VOLUMEDOWN,
++ /* row 2 */
++ 0, 0, 0, KEY_KPENTER,
+ };
+ static unsigned char ezx_direct_keycode[] = {
+ KEY_CAMERA,
+- KEYPAD_NONE,
+- KEYPAD_NONE,
+- KEYPAD_A,
++ 0,
++ 0,
++ KEY_HOME,
+ KEY_POWER,
+- KEYPAD_B,
++ KEY_MENU,
+ };
+ #elif defined(CONFIG_PXA_EZX_A780)
+ static unsigned char ezx_keycode[] = {
+@@ -424,22 +378,12 @@
+ KEY_CAMERA,
+ };
+ #else
+-#error "no EZX subarchitecture defined !?!"
++#error "no EZX subarchitecture defined"
+ #endif
+
+ static int ezx_kbd_init(void)
+ {
+-#if defined(CONFIG_PXA_EZX_E680_P4A)
+- pxa_gpio_mode(93 | GPIO_ALT_FN_1_IN); /* KP_DKIN<0>, VR Key */
+- pxa_gpio_mode(97 | GPIO_ALT_FN_1_IN); /* KP_DKIN<4>, power key */
+- pxa_gpio_mode(100 | GPIO_ALT_FN_1_IN); /* KP_MKIN<0> */
+- pxa_gpio_mode(101 | GPIO_ALT_FN_1_IN); /* KP_MKIN<1> */
+- pxa_gpio_mode(102 | GPIO_ALT_FN_1_IN); /* KP_MKIN<2> */
+- pxa_gpio_mode(103 | GPIO_ALT_FN_2_OUT); /* KP_MKOUT<0> */
+- pxa_gpio_mode(104 | GPIO_ALT_FN_2_OUT); /* KP_MKOUT<1> */
+- pxa_gpio_mode(105 | GPIO_ALT_FN_2_OUT); /* KP_MKOUT<2> */
+- pxa_gpio_mode(106 | GPIO_ALT_FN_2_OUT); /* KP_MKOUT<3> */
+-#elif defined(CONFIG_PXA_EZX_E680)
++#if defined(CONFIG_PXA_EZX_E680)
+ pxa_gpio_mode(93 | GPIO_ALT_FN_1_IN); /* KP_DKIN<0>, VR Key */
+ pxa_gpio_mode(96 | GPIO_ALT_FN_1_IN); /* KP_DKIN<3>, GAME_A */
+ pxa_gpio_mode(97 | GPIO_ALT_FN_1_IN); /* KP_DKIN<4>, power key */
+@@ -455,7 +399,7 @@
+ GPDR(GPIO_TC_MM_EN) |= GPIO_bit(GPIO_TC_MM_EN);
+ GPSR(GPIO_TC_MM_EN) = GPIO_bit(GPIO_TC_MM_EN);
+ PGSR3 |= GPIO_bit(GPIO_TC_MM_EN);
+-#elif defined (CONFIG_PXA_EZX_A780)
++#elif defined(CONFIG_PXA_EZX_A780)
+ pxa_gpio_mode(93 | GPIO_ALT_FN_1_IN); /* KP_DKIN<0>, voice_rec */
+ pxa_gpio_mode(97 | GPIO_ALT_FN_3_IN); /* KP_MKIN<3> */
+ pxa_gpio_mode(98 | GPIO_ALT_FN_3_IN); /* KP_MKIN<4> */
+@@ -476,10 +420,7 @@
+ .scan_interval = HZ/40,
+ .matrix = {
+ .keycode = &ezx_keycode,
+-#if defined(CONFIG_ARCH_EXZ_E680_P4A)
+- .cols = 4,
+- .rows = 3,
+-#elif defined(CONFIG_PXA_EZX_E680)
++#if defined(CONFIG_PXA_EZX_E680)
+ .cols = 4,
+ .rows = 3,
+ #elif defined(CONFIG_PXA_EZX_A780)
+@@ -489,9 +430,7 @@
+ },
+ .direct = {
+ .keycode = &ezx_direct_keycode,
+-#if defined(CONFIG_PXA_EZX_E680_P4A)
+- .num = 4,
+-#elif defined(CONFIG_PXA_EZX_E680)
++#if defined(CONFIG_PXA_EZX_E680)
+ .num = 5,
+ #elif defined(CONFIG_PXA_EZX_A780)
+ .num = 1,
diff --git a/packages/linux/linux-ezx/e680-keypad-compile-HACK.patch b/packages/linux/linux-ezx/e680-keypad-compile-HACK.patch
deleted file mode 100644
index 47d07db695..0000000000
--- a/packages/linux/linux-ezx/e680-keypad-compile-HACK.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-
-#
-# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
-#
-
---- linux-2.6.16/arch/arm/mach-pxa/ezx.c~e680-keypad-compile-fix.patch 2006-05-31 18:47:58.000000000 +0200
-+++ linux-2.6.16/arch/arm/mach-pxa/ezx.c 2006-05-31 18:51:57.000000000 +0200
-@@ -404,24 +404,20 @@
- KEYPAD_NONE,
- };
- #elif defined(CONFIG_PXA_EZX_E680)
--#error "kbd matrix still needs to be converted to new row/col layout"
- static unsigned char ezx_keycode[] = {
-- /* col 0 */
-- KEY_UP, KEY_DOWN, 0, 0, 0, 0, 0, 0,
-- /* col 1 */
-- KEY_RIGHT, KEY_LEFT, 0, 0, 0, 0, 0, 0,
-- /* col 2 */
-- 0, KEYPAD_GAME_R, 0, 0, 0, 0, 0, 0,
-- /* col 3 */
-- KEYPAD_HOME, KEYPAD_GAME_L, KEYPAD_CENTER, 0, 0, 0, 0, 0,
-+ /* row 0 */
-+ KEY_KPENTER, KEY_MENU, KEY_CANCEL, KEY_PAGEUP, KEY_UP,
-+ /* row 1 */
-+ KEY_KP1, KEY_KP2, KEY_KP3, KEY_ENTER, KEY_KPENTER, /*center joypad */
-+ /* row 2 */
-+ KEY_KP4, KEY_KP5, KEY_KP6, KEY_PAGEDOWN, KEY_PHONE,
-+ /* row 3 */
-+ KEY_KP7, KEY_KP8, KEY_KP9, KEY_PHONE, KEY_LEFT,
-+ /* row 4 */
-+ KEY_KPASTERISK, KEY_KP0, KEY_KPDOT, KEY_PAGEDOWN, KEY_DOWN,
- };
- static unsigned char ezx_direct_keycode[] = {
- KEY_CAMERA,
-- KEYPAD_NONE,
-- KEYPAD_NONE,
-- KEYPAD_A,
-- KEY_POWER,
-- KEYPAD_B,
- };
- #elif defined(CONFIG_PXA_EZX_A780)
- static unsigned char ezx_keycode[] = {
diff --git a/packages/linux/linux-ezx/pxakbd-fix-directkeys.patch b/packages/linux/linux-ezx/pxakbd-fix-directkeys.patch
new file mode 100644
index 0000000000..e1d0d7c26e
--- /dev/null
+++ b/packages/linux/linux-ezx/pxakbd-fix-directkeys.patch
@@ -0,0 +1,15 @@
+
+#
+# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
+#
+
+--- linux-2.6.16/drivers/input/keyboard/pxakbd.c~pxakbd-fix-directkeys 2006-06-09 03:16:35.000000000 +0200
++++ linux-2.6.16/drivers/input/keyboard/pxakbd.c 2006-06-09 03:21:04.000000000 +0200
+@@ -279,6 +279,7 @@
+ KPC_ME | KPC_DE | /* matrix and direct keypad enabled */
+ ((pxakbd->pd->matrix.cols-1)<<23) | /* columns */
+ ((pxakbd->pd->matrix.rows-1)<<26) | /* rows */
++ ((pxakbd->pd->direct.num-1)<<6) | /* direct keys */
+ KPC_MS_ALL); /* scan all columns */
+
+ pxa_set_cken(CKEN19_KEYPAD, 1);
diff --git a/packages/linux/linux-ezx_2.6.16.13.bb b/packages/linux/linux-ezx_2.6.16.13.bb
index dcbe494094..f7f9704645 100644
--- a/packages/linux/linux-ezx_2.6.16.13.bb
+++ b/packages/linux/linux-ezx_2.6.16.13.bb
@@ -6,7 +6,7 @@ MAINTAINER = "Michael 'Mickey' Lauer <mickey@vanille.de>"
LICENSE = "GPL"
DEPENDS += "quilt-native"
EZX = "ezx6"
-PR = "${EZX}-r10"
+PR = "${EZX}-r11"
inherit kernel
@@ -35,12 +35,13 @@ SRC_URI = "http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.16.tar.bz2 \
\
file://touchscreen-fix-r0.patch;patch=1 \
\
- file://e680-keypad-compile-HACK.patch;patch=1 \
file://e680-disable-boomer-HACK.patch;patch=1 \
\
file://e680-leds-r1.patch;patch=1 \
file://a780-leds-r0.patch;patch=1 \
file://ezx-backlight-r1.patch;patch=1 \
+ file://e680-fix-keypad.patch;patch=1 \
+ file://pxakbd-fix-directkeys.patch;patch=1 \
\
file://defconfig-a780 \
file://defconfig-e680"