diff options
author | Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> | 2009-10-22 17:43:17 -0400 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2009-10-22 17:43:17 -0400 |
commit | 6135434a54719c45fdc6add1ba4965dea89ab069 (patch) | |
tree | 08e437c116f72edf494593d73f56f5da78b1dfab | |
parent | 012abeea669ea49636cf952d13298bb68654146a (diff) |
omap: Fix omap-keypad by restoring old keypad.h without breaking omap2 boards that use matrix_keypad
Only mach-omap2 boards are currently using matrix_keypad. Allow
mach-omap1 boards to use the old style keypad.h without breaking.
Created against linux-2.6.32-rc5.
Compile tested with omap_3430sdp_defconfig and rx51_defconfig.
Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>
Signed-off-by: Tony Lindgren <tony@atomide.com>
-rw-r--r-- | arch/arm/mach-omap2/board-3430sdp.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-ldp.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-omap3evm.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-omap3pandora.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-rx51-peripherals.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-rx51.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-omap2/board-zoom2.c | 2 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/mach/keypad.h | 5 |
8 files changed, 10 insertions, 8 deletions
diff --git a/arch/arm/mach-omap2/board-3430sdp.c b/arch/arm/mach-omap2/board-3430sdp.c index efaf053eba85..0acb5560229c 100644 --- a/arch/arm/mach-omap2/board-3430sdp.c +++ b/arch/arm/mach-omap2/board-3430sdp.c | |||
@@ -17,6 +17,7 @@ | |||
17 | #include <linux/platform_device.h> | 17 | #include <linux/platform_device.h> |
18 | #include <linux/delay.h> | 18 | #include <linux/delay.h> |
19 | #include <linux/input.h> | 19 | #include <linux/input.h> |
20 | #include <linux/input/matrix_keypad.h> | ||
20 | #include <linux/spi/spi.h> | 21 | #include <linux/spi/spi.h> |
21 | #include <linux/spi/ads7846.h> | 22 | #include <linux/spi/ads7846.h> |
22 | #include <linux/i2c/twl4030.h> | 23 | #include <linux/i2c/twl4030.h> |
@@ -38,7 +39,6 @@ | |||
38 | #include <mach/gpmc.h> | 39 | #include <mach/gpmc.h> |
39 | 40 | ||
40 | #include <mach/control.h> | 41 | #include <mach/control.h> |
41 | #include <mach/keypad.h> | ||
42 | #include <mach/gpmc-smc91x.h> | 42 | #include <mach/gpmc-smc91x.h> |
43 | 43 | ||
44 | #include "sdram-qimonda-hyb18m512160af-6.h" | 44 | #include "sdram-qimonda-hyb18m512160af-6.h" |
diff --git a/arch/arm/mach-omap2/board-ldp.c b/arch/arm/mach-omap2/board-ldp.c index d110a7fdfbd8..d57ec2f4d0a9 100644 --- a/arch/arm/mach-omap2/board-ldp.c +++ b/arch/arm/mach-omap2/board-ldp.c | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <linux/platform_device.h> | 16 | #include <linux/platform_device.h> |
17 | #include <linux/delay.h> | 17 | #include <linux/delay.h> |
18 | #include <linux/input.h> | 18 | #include <linux/input.h> |
19 | #include <linux/input/matrix_keypad.h> | ||
19 | #include <linux/gpio_keys.h> | 20 | #include <linux/gpio_keys.h> |
20 | #include <linux/workqueue.h> | 21 | #include <linux/workqueue.h> |
21 | #include <linux/err.h> | 22 | #include <linux/err.h> |
@@ -41,7 +42,6 @@ | |||
41 | #include <asm/delay.h> | 42 | #include <asm/delay.h> |
42 | #include <mach/control.h> | 43 | #include <mach/control.h> |
43 | #include <mach/usb.h> | 44 | #include <mach/usb.h> |
44 | #include <mach/keypad.h> | ||
45 | 45 | ||
46 | #include "mmc-twl4030.h" | 46 | #include "mmc-twl4030.h" |
47 | 47 | ||
diff --git a/arch/arm/mach-omap2/board-omap3evm.c b/arch/arm/mach-omap2/board-omap3evm.c index e4ec0c591216..4c4d7f8dbd72 100644 --- a/arch/arm/mach-omap2/board-omap3evm.c +++ b/arch/arm/mach-omap2/board-omap3evm.c | |||
@@ -20,6 +20,7 @@ | |||
20 | #include <linux/clk.h> | 20 | #include <linux/clk.h> |
21 | #include <linux/gpio.h> | 21 | #include <linux/gpio.h> |
22 | #include <linux/input.h> | 22 | #include <linux/input.h> |
23 | #include <linux/input/matrix_keypad.h> | ||
23 | #include <linux/leds.h> | 24 | #include <linux/leds.h> |
24 | 25 | ||
25 | #include <linux/spi/spi.h> | 26 | #include <linux/spi/spi.h> |
@@ -37,7 +38,6 @@ | |||
37 | #include <mach/usb.h> | 38 | #include <mach/usb.h> |
38 | #include <mach/common.h> | 39 | #include <mach/common.h> |
39 | #include <mach/mcspi.h> | 40 | #include <mach/mcspi.h> |
40 | #include <mach/keypad.h> | ||
41 | 41 | ||
42 | #include "sdram-micron-mt46h32m32lf-6.h" | 42 | #include "sdram-micron-mt46h32m32lf-6.h" |
43 | #include "mmc-twl4030.h" | 43 | #include "mmc-twl4030.h" |
diff --git a/arch/arm/mach-omap2/board-omap3pandora.c b/arch/arm/mach-omap2/board-omap3pandora.c index 7f6bf8772af7..5326e0d61597 100644 --- a/arch/arm/mach-omap2/board-omap3pandora.c +++ b/arch/arm/mach-omap2/board-omap3pandora.c | |||
@@ -27,6 +27,7 @@ | |||
27 | #include <linux/i2c/twl4030.h> | 27 | #include <linux/i2c/twl4030.h> |
28 | #include <linux/leds.h> | 28 | #include <linux/leds.h> |
29 | #include <linux/input.h> | 29 | #include <linux/input.h> |
30 | #include <linux/input/matrix_keypad.h> | ||
30 | #include <linux/gpio_keys.h> | 31 | #include <linux/gpio_keys.h> |
31 | 32 | ||
32 | #include <asm/mach-types.h> | 33 | #include <asm/mach-types.h> |
@@ -39,7 +40,6 @@ | |||
39 | #include <mach/hardware.h> | 40 | #include <mach/hardware.h> |
40 | #include <mach/mcspi.h> | 41 | #include <mach/mcspi.h> |
41 | #include <mach/usb.h> | 42 | #include <mach/usb.h> |
42 | #include <mach/keypad.h> | ||
43 | #include <mach/mux.h> | 43 | #include <mach/mux.h> |
44 | 44 | ||
45 | #include "sdram-micron-mt46h32m32lf-6.h" | 45 | #include "sdram-micron-mt46h32m32lf-6.h" |
diff --git a/arch/arm/mach-omap2/board-rx51-peripherals.c b/arch/arm/mach-omap2/board-rx51-peripherals.c index 2b0eb1ba5d7f..e34d96a825e3 100644 --- a/arch/arm/mach-omap2/board-rx51-peripherals.c +++ b/arch/arm/mach-omap2/board-rx51-peripherals.c | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/init.h> | 12 | #include <linux/init.h> |
13 | #include <linux/platform_device.h> | 13 | #include <linux/platform_device.h> |
14 | #include <linux/input.h> | 14 | #include <linux/input.h> |
15 | #include <linux/input/matrix_keypad.h> | ||
15 | #include <linux/spi/spi.h> | 16 | #include <linux/spi/spi.h> |
16 | #include <linux/i2c.h> | 17 | #include <linux/i2c.h> |
17 | #include <linux/i2c/twl4030.h> | 18 | #include <linux/i2c/twl4030.h> |
@@ -27,7 +28,6 @@ | |||
27 | #include <mach/common.h> | 28 | #include <mach/common.h> |
28 | #include <mach/dma.h> | 29 | #include <mach/dma.h> |
29 | #include <mach/gpmc.h> | 30 | #include <mach/gpmc.h> |
30 | #include <mach/keypad.h> | ||
31 | #include <mach/onenand.h> | 31 | #include <mach/onenand.h> |
32 | #include <mach/gpmc-smc91x.h> | 32 | #include <mach/gpmc-smc91x.h> |
33 | 33 | ||
diff --git a/arch/arm/mach-omap2/board-rx51.c b/arch/arm/mach-omap2/board-rx51.c index f9196c3b1a7b..78869a9a1cc2 100644 --- a/arch/arm/mach-omap2/board-rx51.c +++ b/arch/arm/mach-omap2/board-rx51.c | |||
@@ -26,7 +26,6 @@ | |||
26 | #include <mach/mux.h> | 26 | #include <mach/mux.h> |
27 | #include <mach/board.h> | 27 | #include <mach/board.h> |
28 | #include <mach/common.h> | 28 | #include <mach/common.h> |
29 | #include <mach/keypad.h> | ||
30 | #include <mach/dma.h> | 29 | #include <mach/dma.h> |
31 | #include <mach/gpmc.h> | 30 | #include <mach/gpmc.h> |
32 | #include <mach/usb.h> | 31 | #include <mach/usb.h> |
diff --git a/arch/arm/mach-omap2/board-zoom2.c b/arch/arm/mach-omap2/board-zoom2.c index fd3369d5e5cb..ea00486a5e53 100644 --- a/arch/arm/mach-omap2/board-zoom2.c +++ b/arch/arm/mach-omap2/board-zoom2.c | |||
@@ -13,6 +13,7 @@ | |||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/platform_device.h> | 14 | #include <linux/platform_device.h> |
15 | #include <linux/input.h> | 15 | #include <linux/input.h> |
16 | #include <linux/input/matrix_keypad.h> | ||
16 | #include <linux/gpio.h> | 17 | #include <linux/gpio.h> |
17 | #include <linux/i2c/twl4030.h> | 18 | #include <linux/i2c/twl4030.h> |
18 | #include <linux/regulator/machine.h> | 19 | #include <linux/regulator/machine.h> |
@@ -22,7 +23,6 @@ | |||
22 | 23 | ||
23 | #include <mach/common.h> | 24 | #include <mach/common.h> |
24 | #include <mach/usb.h> | 25 | #include <mach/usb.h> |
25 | #include <mach/keypad.h> | ||
26 | 26 | ||
27 | #include "mmc-twl4030.h" | 27 | #include "mmc-twl4030.h" |
28 | #include "sdram-micron-mt46h32m32lf-6.h" | 28 | #include "sdram-micron-mt46h32m32lf-6.h" |
diff --git a/arch/arm/plat-omap/include/mach/keypad.h b/arch/arm/plat-omap/include/mach/keypad.h index d91b9be334ff..3ae52ccc793c 100644 --- a/arch/arm/plat-omap/include/mach/keypad.h +++ b/arch/arm/plat-omap/include/mach/keypad.h | |||
@@ -10,7 +10,7 @@ | |||
10 | #ifndef ASMARM_ARCH_KEYPAD_H | 10 | #ifndef ASMARM_ARCH_KEYPAD_H |
11 | #define ASMARM_ARCH_KEYPAD_H | 11 | #define ASMARM_ARCH_KEYPAD_H |
12 | 12 | ||
13 | #include <linux/input/matrix_keypad.h> | 13 | #warning: Please update the board to use matrix_keypad.h instead |
14 | 14 | ||
15 | struct omap_kp_platform_data { | 15 | struct omap_kp_platform_data { |
16 | int rows; | 16 | int rows; |
@@ -37,6 +37,9 @@ struct omap_kp_platform_data { | |||
37 | 37 | ||
38 | #define KEY_PERSISTENT 0x00800000 | 38 | #define KEY_PERSISTENT 0x00800000 |
39 | #define KEYNUM_MASK 0x00EFFFFF | 39 | #define KEYNUM_MASK 0x00EFFFFF |
40 | #define KEY(col, row, val) (((col) << 28) | ((row) << 24) | (val)) | ||
41 | #define PERSISTENT_KEY(col, row) (((col) << 28) | ((row) << 24) | \ | ||
42 | KEY_PERSISTENT) | ||
40 | 43 | ||
41 | #endif | 44 | #endif |
42 | 45 | ||