diff options
author | Shawn Guo <shawn.guo@linaro.org> | 2011-12-02 07:00:33 -0500 |
---|---|---|
committer | Shawn Guo <shawn.guo@linaro.org> | 2012-07-01 09:57:06 -0400 |
commit | ed175343b4b53d686e30b1e37fb94e142f56fa2f (patch) | |
tree | c7d8c37edafa9d6f9c06034bbb6a9c7bf00dfe7f /arch/arm/mach-imx/mach-mx31lilly.c | |
parent | 84715dd6c19e058557ab173d327ea65eac0ccb02 (diff) |
ARM: imx: eliminate macro IOMUX_TO_IRQ()
This patch changes all the static gpio irq number assigning with
IOMUX_TO_IRQ() to run-time assigning with gpio_to_irq call, and
in turn eliminates the macro IOMUX_TO_IRQ().
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Dong Aisheng <dong.aisheng@linaro.org>
Diffstat (limited to 'arch/arm/mach-imx/mach-mx31lilly.c')
-rw-r--r-- | arch/arm/mach-imx/mach-mx31lilly.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/arch/arm/mach-imx/mach-mx31lilly.c b/arch/arm/mach-imx/mach-mx31lilly.c index 83714b0cc290..34b9bf075daf 100644 --- a/arch/arm/mach-imx/mach-mx31lilly.c +++ b/arch/arm/mach-imx/mach-mx31lilly.c | |||
@@ -65,8 +65,7 @@ static struct resource smsc91x_resources[] = { | |||
65 | .flags = IORESOURCE_MEM, | 65 | .flags = IORESOURCE_MEM, |
66 | }, | 66 | }, |
67 | { | 67 | { |
68 | .start = IOMUX_TO_IRQ(MX31_PIN_GPIO1_0), | 68 | /* irq number is run-time assigned */ |
69 | .end = IOMUX_TO_IRQ(MX31_PIN_GPIO1_0), | ||
70 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_FALLING, | 69 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_FALLING, |
71 | } | 70 | } |
72 | }; | 71 | }; |
@@ -233,7 +232,7 @@ static struct spi_board_info mc13783_dev __initdata = { | |||
233 | .bus_num = 1, | 232 | .bus_num = 1, |
234 | .chip_select = 0, | 233 | .chip_select = 0, |
235 | .platform_data = &mc13783_pdata, | 234 | .platform_data = &mc13783_pdata, |
236 | .irq = IOMUX_TO_IRQ(MX31_PIN_GPIO1_3), | 235 | /* irq number is run-time assigned */ |
237 | }; | 236 | }; |
238 | 237 | ||
239 | static struct platform_device *devices[] __initdata = { | 238 | static struct platform_device *devices[] __initdata = { |
@@ -285,10 +284,15 @@ static void __init mx31lilly_board_init(void) | |||
285 | 284 | ||
286 | imx31_add_spi_imx0(&spi0_pdata); | 285 | imx31_add_spi_imx0(&spi0_pdata); |
287 | imx31_add_spi_imx1(&spi1_pdata); | 286 | imx31_add_spi_imx1(&spi1_pdata); |
287 | mc13783_dev.irq = gpio_to_irq(IOMUX_TO_GPIO(MX31_PIN_GPIO1_3)); | ||
288 | spi_register_board_info(&mc13783_dev, 1); | 288 | spi_register_board_info(&mc13783_dev, 1); |
289 | 289 | ||
290 | regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); | 290 | regulator_register_fixed(0, dummy_supplies, ARRAY_SIZE(dummy_supplies)); |
291 | 291 | ||
292 | smsc91x_resources[1].start = | ||
293 | gpio_to_irq(IOMUX_TO_GPIO(MX31_PIN_GPIO1_0)); | ||
294 | smsc91x_resources[1].end = | ||
295 | gpio_to_irq(IOMUX_TO_GPIO(MX31_PIN_GPIO1_0)); | ||
292 | platform_add_devices(devices, ARRAY_SIZE(devices)); | 296 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
293 | 297 | ||
294 | /* USB */ | 298 | /* USB */ |