aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c')
-rw-r--r--arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c16
1 files changed, 3 insertions, 13 deletions
diff --git a/arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c b/arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c
index e6c1119c20ae..31c871ec46a6 100644
--- a/arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c
+++ b/arch/arm/mach-mx5/eukrea_mbimxsd-baseboard.c
@@ -27,7 +27,6 @@
27#include <linux/irq.h> 27#include <linux/irq.h>
28#include <linux/leds.h> 28#include <linux/leds.h>
29#include <linux/platform_device.h> 29#include <linux/platform_device.h>
30#include <linux/gpio_keys.h>
31#include <linux/input.h> 30#include <linux/input.h>
32#include <linux/i2c.h> 31#include <linux/i2c.h>
33 32
@@ -38,7 +37,6 @@
38 37
39#include <mach/hardware.h> 38#include <mach/hardware.h>
40#include <mach/common.h> 39#include <mach/common.h>
41#include <mach/imx-uart.h>
42#include <mach/iomux-mx51.h> 40#include <mach/iomux-mx51.h>
43#include <mach/audmux.h> 41#include <mach/audmux.h>
44 42
@@ -108,23 +106,14 @@ static struct gpio_keys_button eukrea_mbimxsd_gpio_buttons[] = {
108 }, 106 },
109}; 107};
110 108
111static struct gpio_keys_platform_data eukrea_mbimxsd_button_data = { 109static const struct gpio_keys_platform_data
110 eukrea_mbimxsd_button_data __initconst = {
112 .buttons = eukrea_mbimxsd_gpio_buttons, 111 .buttons = eukrea_mbimxsd_gpio_buttons,
113 .nbuttons = ARRAY_SIZE(eukrea_mbimxsd_gpio_buttons), 112 .nbuttons = ARRAY_SIZE(eukrea_mbimxsd_gpio_buttons),
114}; 113};
115 114
116static struct platform_device eukrea_mbimxsd_button_device = {
117 .name = "gpio-keys",
118 .id = -1,
119 .num_resources = 0,
120 .dev = {
121 .platform_data = &eukrea_mbimxsd_button_data,
122 }
123};
124
125static struct platform_device *platform_devices[] __initdata = { 115static struct platform_device *platform_devices[] __initdata = {
126 &eukrea_mbimxsd_leds_gpio, 116 &eukrea_mbimxsd_leds_gpio,
127 &eukrea_mbimxsd_button_device,
128}; 117};
129 118
130static const struct imxuart_platform_data uart_pdata __initconst = { 119static const struct imxuart_platform_data uart_pdata __initconst = {
@@ -166,4 +155,5 @@ void __init eukrea_mbimxsd51_baseboard_init(void)
166 ARRAY_SIZE(eukrea_mbimxsd_i2c_devices)); 155 ARRAY_SIZE(eukrea_mbimxsd_i2c_devices));
167 156
168 platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); 157 platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices));
158 imx_add_gpio_keys(&eukrea_mbimxsd_button_data);
169} 159}