diff options
author | Haojian Zhuang <haojian.zhuang@linaro.org> | 2013-04-09 06:12:04 -0400 |
---|---|---|
committer | Haojian Zhuang <haojian.zhuang@linaro.org> | 2013-04-10 22:00:05 -0400 |
commit | b8f649f1f531914a30ecb420e7565ee04dccc2ad (patch) | |
tree | 42b2bc905fce1c892511ff81a250d7330b33a4ed /arch/arm/mach-mmp/brownstone.c | |
parent | 2cab0292285ce3180224c130d2fb1104aee44ff1 (diff) |
ARM: pxa: move PXA_GPIO_TO_IRQ macro
Since PXA_GPIO_TO_IRQ() & MMP_GPIO_TO_IRQ() macro are depended on
arch code, move them from gpio driver to platform driver instead.
Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'arch/arm/mach-mmp/brownstone.c')
-rw-r--r-- | arch/arm/mach-mmp/brownstone.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/arm/mach-mmp/brownstone.c b/arch/arm/mach-mmp/brownstone.c index 2358011c7d8e..ac25544b8cdb 100644 --- a/arch/arm/mach-mmp/brownstone.c +++ b/arch/arm/mach-mmp/brownstone.c | |||
@@ -14,6 +14,7 @@ | |||
14 | #include <linux/kernel.h> | 14 | #include <linux/kernel.h> |
15 | #include <linux/platform_device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/io.h> | 16 | #include <linux/io.h> |
17 | #include <linux/gpio-pxa.h> | ||
17 | #include <linux/regulator/machine.h> | 18 | #include <linux/regulator/machine.h> |
18 | #include <linux/regulator/max8649.h> | 19 | #include <linux/regulator/max8649.h> |
19 | #include <linux/regulator/fixed.h> | 20 | #include <linux/regulator/fixed.h> |
@@ -104,6 +105,10 @@ static unsigned long brownstone_pin_config[] __initdata = { | |||
104 | GPIO89_GPIO, | 105 | GPIO89_GPIO, |
105 | }; | 106 | }; |
106 | 107 | ||
108 | static struct pxa_gpio_platform_data mmp2_gpio_pdata = { | ||
109 | .irq_base = MMP_GPIO_TO_IRQ(0), | ||
110 | }; | ||
111 | |||
107 | static struct regulator_consumer_supply max8649_supply[] = { | 112 | static struct regulator_consumer_supply max8649_supply[] = { |
108 | REGULATOR_SUPPLY("vcc_core", NULL), | 113 | REGULATOR_SUPPLY("vcc_core", NULL), |
109 | }; | 114 | }; |
@@ -202,6 +207,8 @@ static void __init brownstone_init(void) | |||
202 | /* on-chip devices */ | 207 | /* on-chip devices */ |
203 | mmp2_add_uart(1); | 208 | mmp2_add_uart(1); |
204 | mmp2_add_uart(3); | 209 | mmp2_add_uart(3); |
210 | platform_device_add_data(&mmp2_device_gpio, &mmp2_gpio_pdata, | ||
211 | sizeof(struct pxa_gpio_platform_data)); | ||
205 | platform_device_register(&mmp2_device_gpio); | 212 | platform_device_register(&mmp2_device_gpio); |
206 | mmp2_add_twsi(1, NULL, ARRAY_AND_SIZE(brownstone_twsi1_info)); | 213 | mmp2_add_twsi(1, NULL, ARRAY_AND_SIZE(brownstone_twsi1_info)); |
207 | mmp2_add_sdhost(0, &mmp2_sdh_platdata_mmc0); /* SD/MMC */ | 214 | mmp2_add_sdhost(0, &mmp2_sdh_platdata_mmc0); /* SD/MMC */ |