aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx25
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2010-11-11 05:35:33 -0500
committerUwe Kleine-König <u.kleine-koenig@pengutronix.de>2010-11-17 04:01:39 -0500
commitab9cee4b2167f8bf01d85b537df5b9cbe342c780 (patch)
treedb37c9d9263e1a2aea6c3c6b08b904c0163e905e /arch/arm/mach-mx25
parentd485c7e71675abdd6133128e596b41284c2ee7b5 (diff)
ARM: mx25: dynamically allocate imx-keypad devices
The mxc-keypad device seems to be the result of an early and partial merge of the keypad driver. It's unused and there is no corresponding driver available, so just remove it. Cc: Alberto Panizzo <maramaopercheseimorto@gmail.com> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx25')
-rw-r--r--arch/arm/mach-mx25/Kconfig3
-rw-r--r--arch/arm/mach-mx25/devices-imx25.h4
-rw-r--r--arch/arm/mach-mx25/devices.c39
-rw-r--r--arch/arm/mach-mx25/devices.h2
-rw-r--r--arch/arm/mach-mx25/mach-mx25_3ds.c4
5 files changed, 8 insertions, 44 deletions
diff --git a/arch/arm/mach-mx25/Kconfig b/arch/arm/mach-mx25/Kconfig
index 2944bb71b031..e9d445649d4d 100644
--- a/arch/arm/mach-mx25/Kconfig
+++ b/arch/arm/mach-mx25/Kconfig
@@ -4,10 +4,11 @@ comment "MX25 platforms:"
4 4
5config MACH_MX25_3DS 5config MACH_MX25_3DS
6 bool "Support MX25PDK (3DS) Platform" 6 bool "Support MX25PDK (3DS) Platform"
7 select IMX_HAVE_PLATFORM_ESDHC
8 select IMX_HAVE_PLATFORM_IMX_KEYPAD
7 select IMX_HAVE_PLATFORM_IMX_UART 9 select IMX_HAVE_PLATFORM_IMX_UART
8 select IMX_HAVE_PLATFORM_MXC_EHCI 10 select IMX_HAVE_PLATFORM_MXC_EHCI
9 select IMX_HAVE_PLATFORM_MXC_NAND 11 select IMX_HAVE_PLATFORM_MXC_NAND
10 select IMX_HAVE_PLATFORM_ESDHC
11 12
12config MACH_EUKREA_CPUIMX25 13config MACH_EUKREA_CPUIMX25
13 bool "Support Eukrea CPUIMX25 Platform" 14 bool "Support Eukrea CPUIMX25 Platform"
diff --git a/arch/arm/mach-mx25/devices-imx25.h b/arch/arm/mach-mx25/devices-imx25.h
index 448939aac02c..a35123fef39f 100644
--- a/arch/arm/mach-mx25/devices-imx25.h
+++ b/arch/arm/mach-mx25/devices-imx25.h
@@ -30,6 +30,10 @@ extern const struct imx_imx_i2c_data imx25_imx_i2c_data[] __initconst;
30#define imx25_add_imx_i2c1(pdata) imx25_add_imx_i2c(1, pdata) 30#define imx25_add_imx_i2c1(pdata) imx25_add_imx_i2c(1, pdata)
31#define imx25_add_imx_i2c2(pdata) imx25_add_imx_i2c(2, pdata) 31#define imx25_add_imx_i2c2(pdata) imx25_add_imx_i2c(2, pdata)
32 32
33extern const struct imx_imx_keypad_data imx25_imx_keypad_data __initconst;
34#define imx25_add_imx_keypad(pdata) \
35 imx_add_imx_keypad(&imx25_imx_keypad_data, pdata)
36
33extern const struct imx_imx_ssi_data imx25_imx_ssi_data[] __initconst; 37extern const struct imx_imx_ssi_data imx25_imx_ssi_data[] __initconst;
34#define imx25_add_imx_ssi(id, pdata) \ 38#define imx25_add_imx_ssi(id, pdata) \
35 imx_add_imx_ssi(&imx25_imx_ssi_data[id], pdata) 39 imx_add_imx_ssi(&imx25_imx_ssi_data[id], pdata)
diff --git a/arch/arm/mach-mx25/devices.c b/arch/arm/mach-mx25/devices.c
index 1798be90a382..052adbbb3de6 100644
--- a/arch/arm/mach-mx25/devices.c
+++ b/arch/arm/mach-mx25/devices.c
@@ -22,25 +22,6 @@
22#include <mach/mx25.h> 22#include <mach/mx25.h>
23#include <mach/irqs.h> 23#include <mach/irqs.h>
24 24
25static struct resource mxc_keypad_resources[] = {
26 {
27 .start = 0x43fa8000,
28 .end = 0x43fabfff,
29 .flags = IORESOURCE_MEM,
30 }, {
31 .start = 24,
32 .end = 24,
33 .flags = IORESOURCE_IRQ,
34 }
35};
36
37struct platform_device mxc_keypad_device = {
38 .name = "mxc-keypad",
39 .id = -1,
40 .num_resources = ARRAY_SIZE(mxc_keypad_resources),
41 .resource = mxc_keypad_resources,
42};
43
44static struct resource mx25_rtc_resources[] = { 25static struct resource mx25_rtc_resources[] = {
45 { 26 {
46 .start = MX25_DRYICE_BASE_ADDR, 27 .start = MX25_DRYICE_BASE_ADDR,
@@ -98,26 +79,6 @@ struct platform_device mxc_wdt = {
98 .resource = mxc_wdt_resources, 79 .resource = mxc_wdt_resources,
99}; 80};
100 81
101static struct resource mx25_kpp_resources[] = {
102 {
103 .start = MX25_KPP_BASE_ADDR,
104 .end = MX25_KPP_BASE_ADDR + 0xf,
105 .flags = IORESOURCE_MEM,
106 },
107 {
108 .start = MX25_INT_KPP,
109 .end = MX25_INT_KPP,
110 .flags = IORESOURCE_IRQ,
111 },
112};
113
114struct platform_device mx25_kpp_device = {
115 .name = "imx-keypad",
116 .id = -1,
117 .num_resources = ARRAY_SIZE(mx25_kpp_resources),
118 .resource = mx25_kpp_resources,
119};
120
121static struct resource mx25_csi_resources[] = { 82static struct resource mx25_csi_resources[] = {
122 { 83 {
123 .start = MX25_CSI_BASE_ADDR, 84 .start = MX25_CSI_BASE_ADDR,
diff --git a/arch/arm/mach-mx25/devices.h b/arch/arm/mach-mx25/devices.h
index afc60ddc6a31..dd1fdeddb83b 100644
--- a/arch/arm/mach-mx25/devices.h
+++ b/arch/arm/mach-mx25/devices.h
@@ -1,6 +1,4 @@
1extern struct platform_device mxc_keypad_device;
2extern struct platform_device mx25_rtc_device; 1extern struct platform_device mx25_rtc_device;
3extern struct platform_device mx25_fb_device; 2extern struct platform_device mx25_fb_device;
4extern struct platform_device mxc_wdt; 3extern struct platform_device mxc_wdt;
5extern struct platform_device mx25_kpp_device;
6extern struct platform_device mx25_csi_device; 4extern struct platform_device mx25_csi_device;
diff --git a/arch/arm/mach-mx25/mach-mx25_3ds.c b/arch/arm/mach-mx25/mach-mx25_3ds.c
index 574c41f510df..1d07cfbd8ff6 100644
--- a/arch/arm/mach-mx25/mach-mx25_3ds.c
+++ b/arch/arm/mach-mx25/mach-mx25_3ds.c
@@ -181,7 +181,7 @@ static const uint32_t mx25pdk_keymap[] = {
181 KEY(3, 3, KEY_POWER), 181 KEY(3, 3, KEY_POWER),
182}; 182};
183 183
184static struct matrix_keymap_data mx25pdk_keymap_data = { 184static const struct matrix_keymap_data mx25pdk_keymap_data __initdata = {
185 .keymap = mx25pdk_keymap, 185 .keymap = mx25pdk_keymap,
186 .keymap_size = ARRAY_SIZE(mx25pdk_keymap), 186 .keymap_size = ARRAY_SIZE(mx25pdk_keymap),
187}; 187};
@@ -200,7 +200,7 @@ static void __init mx25pdk_init(void)
200 200
201 mx25pdk_fec_reset(); 201 mx25pdk_fec_reset();
202 imx25_add_fec(&mx25_fec_pdata); 202 imx25_add_fec(&mx25_fec_pdata);
203 mxc_register_device(&mx25_kpp_device, &mx25pdk_keymap_data); 203 imx25_add_imx_keypad(&mx25pdk_keymap_data);
204 204
205 imx25_add_esdhc(0, NULL); 205 imx25_add_esdhc(0, NULL);
206} 206}