diff options
-rw-r--r-- | arch/arm/mach-imx/devices.c | 22 | ||||
-rw-r--r-- | arch/arm/mach-imx/mm-imx21.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-imx/mm-imx27.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mx1/devices.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-mx1/generic.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mx25/devices.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-mx25/mm.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mx3/devices.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-mx3/mm.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mx5/devices.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-mx5/mm.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-mxc91231/devices.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-mxc91231/mm.c | 3 | ||||
-rw-r--r-- | arch/arm/plat-mxc/irq.c | 3 | ||||
-rw-r--r-- | arch/arm/plat-mxc/tzic.c | 2 |
15 files changed, 34 insertions, 24 deletions
diff --git a/arch/arm/mach-imx/devices.c b/arch/arm/mach-imx/devices.c index a0aeb8a4adc1..e708bfd9aabc 100644 --- a/arch/arm/mach-imx/devices.c +++ b/arch/arm/mach-imx/devices.c | |||
@@ -454,26 +454,21 @@ DEFINE_IMX_SSI_DEVICE(1, 2, MX2x_SSI1_BASE_ADDR, MX2x_INT_SSI1); | |||
454 | 454 | ||
455 | #ifdef CONFIG_MACH_MX21 | 455 | #ifdef CONFIG_MACH_MX21 |
456 | DEFINE_MXC_GPIO_PORTS(MX21, imx21); | 456 | DEFINE_MXC_GPIO_PORTS(MX21, imx21); |
457 | |||
458 | int __init imx21_register_gpios(void) | ||
459 | { | ||
460 | return mxc_gpio_init(imx21_gpio_ports, ARRAY_SIZE(imx21_gpio_ports)); | ||
461 | } | ||
457 | #endif | 462 | #endif |
458 | 463 | ||
459 | #ifdef CONFIG_MACH_MX27 | 464 | #ifdef CONFIG_MACH_MX27 |
460 | DEFINE_MXC_GPIO_PORTS(MX27, imx27); | 465 | DEFINE_MXC_GPIO_PORTS(MX27, imx27); |
461 | #endif | ||
462 | 466 | ||
463 | int __init mxc_register_gpios(void) | 467 | int __init imx27_register_gpios(void) |
464 | { | 468 | { |
465 | #ifdef CONFIG_MACH_MX21 | 469 | return mxc_gpio_init(imx27_gpio_ports, ARRAY_SIZE(imx27_gpio_ports)); |
466 | if (cpu_is_mx21()) | ||
467 | return mxc_gpio_init(imx21_gpio_ports, ARRAY_SIZE(imx21_gpio_ports)); | ||
468 | else | ||
469 | #endif | ||
470 | #ifdef CONFIG_MACH_MX27 | ||
471 | if (cpu_is_mx27()) | ||
472 | return mxc_gpio_init(imx27_gpio_ports, ARRAY_SIZE(imx27_gpio_ports)); | ||
473 | else | ||
474 | #endif | ||
475 | return 0; | ||
476 | } | 470 | } |
471 | #endif | ||
477 | 472 | ||
478 | #ifdef CONFIG_MACH_MX21 | 473 | #ifdef CONFIG_MACH_MX21 |
479 | static struct resource mx21_usbhc_resources[] = { | 474 | static struct resource mx21_usbhc_resources[] = { |
@@ -500,4 +495,3 @@ struct platform_device mx21_usbhc_device = { | |||
500 | .resource = mx21_usbhc_resources, | 495 | .resource = mx21_usbhc_resources, |
501 | }; | 496 | }; |
502 | #endif | 497 | #endif |
503 | |||
diff --git a/arch/arm/mach-imx/mm-imx21.c b/arch/arm/mach-imx/mm-imx21.c index 115c21289125..68aa5d2ecdb1 100644 --- a/arch/arm/mach-imx/mm-imx21.c +++ b/arch/arm/mach-imx/mm-imx21.c | |||
@@ -77,7 +77,10 @@ void __init mx21_map_io(void) | |||
77 | iotable_init(imx21_io_desc, ARRAY_SIZE(imx21_io_desc)); | 77 | iotable_init(imx21_io_desc, ARRAY_SIZE(imx21_io_desc)); |
78 | } | 78 | } |
79 | 79 | ||
80 | int imx21_register_gpios(void); | ||
81 | |||
80 | void __init mx21_init_irq(void) | 82 | void __init mx21_init_irq(void) |
81 | { | 83 | { |
84 | imx21_register_gpios(); | ||
82 | mxc_init_irq(MX21_IO_ADDRESS(MX21_AVIC_BASE_ADDR)); | 85 | mxc_init_irq(MX21_IO_ADDRESS(MX21_AVIC_BASE_ADDR)); |
83 | } | 86 | } |
diff --git a/arch/arm/mach-imx/mm-imx27.c b/arch/arm/mach-imx/mm-imx27.c index 89b41749e166..bcedce9c87dd 100644 --- a/arch/arm/mach-imx/mm-imx27.c +++ b/arch/arm/mach-imx/mm-imx27.c | |||
@@ -77,7 +77,10 @@ void __init mx27_map_io(void) | |||
77 | iotable_init(imx27_io_desc, ARRAY_SIZE(imx27_io_desc)); | 77 | iotable_init(imx27_io_desc, ARRAY_SIZE(imx27_io_desc)); |
78 | } | 78 | } |
79 | 79 | ||
80 | int imx27_register_gpios(void); | ||
81 | |||
80 | void __init mx27_init_irq(void) | 82 | void __init mx27_init_irq(void) |
81 | { | 83 | { |
84 | imx27_register_gpios(); | ||
82 | mxc_init_irq(MX27_IO_ADDRESS(MX27_AVIC_BASE_ADDR)); | 85 | mxc_init_irq(MX27_IO_ADDRESS(MX27_AVIC_BASE_ADDR)); |
83 | } | 86 | } |
diff --git a/arch/arm/mach-mx1/devices.c b/arch/arm/mach-mx1/devices.c index 8064f2c3b86f..860cbb7397d5 100644 --- a/arch/arm/mach-mx1/devices.c +++ b/arch/arm/mach-mx1/devices.c | |||
@@ -237,7 +237,7 @@ static struct mxc_gpio_port imx_gpio_ports[] = { | |||
237 | } | 237 | } |
238 | }; | 238 | }; |
239 | 239 | ||
240 | int __init mxc_register_gpios(void) | 240 | int __init imx1_register_gpios(void) |
241 | { | 241 | { |
242 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); | 242 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); |
243 | } | 243 | } |
diff --git a/arch/arm/mach-mx1/generic.c b/arch/arm/mach-mx1/generic.c index 5a745d99e660..a9be5f14bd9d 100644 --- a/arch/arm/mach-mx1/generic.c +++ b/arch/arm/mach-mx1/generic.c | |||
@@ -46,7 +46,10 @@ void __init mx1_map_io(void) | |||
46 | iotable_init(imx_io_desc, ARRAY_SIZE(imx_io_desc)); | 46 | iotable_init(imx_io_desc, ARRAY_SIZE(imx_io_desc)); |
47 | } | 47 | } |
48 | 48 | ||
49 | int imx1_register_gpios(void); | ||
50 | |||
49 | void __init mx1_init_irq(void) | 51 | void __init mx1_init_irq(void) |
50 | { | 52 | { |
53 | imx1_register_gpios(); | ||
51 | mxc_init_irq(MX1_IO_ADDRESS(MX1_AVIC_BASE_ADDR)); | 54 | mxc_init_irq(MX1_IO_ADDRESS(MX1_AVIC_BASE_ADDR)); |
52 | } | 55 | } |
diff --git a/arch/arm/mach-mx25/devices.c b/arch/arm/mach-mx25/devices.c index 3a405fa400eb..80f313180713 100644 --- a/arch/arm/mach-mx25/devices.c +++ b/arch/arm/mach-mx25/devices.c | |||
@@ -414,7 +414,7 @@ static struct mxc_gpio_port imx_gpio_ports[] = { | |||
414 | } | 414 | } |
415 | }; | 415 | }; |
416 | 416 | ||
417 | int __init mxc_register_gpios(void) | 417 | int __init imx25_register_gpios(void) |
418 | { | 418 | { |
419 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); | 419 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); |
420 | } | 420 | } |
diff --git a/arch/arm/mach-mx25/mm.c b/arch/arm/mach-mx25/mm.c index a7e587ff3e9e..cf4d76e0d22d 100644 --- a/arch/arm/mach-mx25/mm.c +++ b/arch/arm/mach-mx25/mm.c | |||
@@ -69,8 +69,11 @@ void __init mx25_map_io(void) | |||
69 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | 69 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
70 | } | 70 | } |
71 | 71 | ||
72 | int imx25_register_gpios(void); | ||
73 | |||
72 | void __init mx25_init_irq(void) | 74 | void __init mx25_init_irq(void) |
73 | { | 75 | { |
76 | imx25_register_gpios(); | ||
74 | mxc_init_irq((void __iomem *)MX25_AVIC_BASE_ADDR_VIRT); | 77 | mxc_init_irq((void __iomem *)MX25_AVIC_BASE_ADDR_VIRT); |
75 | } | 78 | } |
76 | 79 | ||
diff --git a/arch/arm/mach-mx3/devices.c b/arch/arm/mach-mx3/devices.c index db7acd6e9101..f6da0ffbe719 100644 --- a/arch/arm/mach-mx3/devices.c +++ b/arch/arm/mach-mx3/devices.c | |||
@@ -147,7 +147,7 @@ static struct mxc_gpio_port imx_gpio_ports[] = { | |||
147 | } | 147 | } |
148 | }; | 148 | }; |
149 | 149 | ||
150 | int __init mxc_register_gpios(void) | 150 | int __init imx3x_register_gpios(void) |
151 | { | 151 | { |
152 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); | 152 | return mxc_gpio_init(imx_gpio_ports, ARRAY_SIZE(imx_gpio_ports)); |
153 | } | 153 | } |
diff --git a/arch/arm/mach-mx3/mm.c b/arch/arm/mach-mx3/mm.c index 6858a4f9806c..595cf09b2c59 100644 --- a/arch/arm/mach-mx3/mm.c +++ b/arch/arm/mach-mx3/mm.c | |||
@@ -97,8 +97,11 @@ void __init mx35_map_io(void) | |||
97 | } | 97 | } |
98 | #endif | 98 | #endif |
99 | 99 | ||
100 | int imx3x_register_gpios(void); | ||
101 | |||
100 | void __init mx31_init_irq(void) | 102 | void __init mx31_init_irq(void) |
101 | { | 103 | { |
104 | imx3x_register_gpios(); | ||
102 | mxc_init_irq(IO_ADDRESS(AVIC_BASE_ADDR)); | 105 | mxc_init_irq(IO_ADDRESS(AVIC_BASE_ADDR)); |
103 | } | 106 | } |
104 | 107 | ||
diff --git a/arch/arm/mach-mx5/devices.c b/arch/arm/mach-mx5/devices.c index 7130449aacdc..f40778f1a877 100644 --- a/arch/arm/mach-mx5/devices.c +++ b/arch/arm/mach-mx5/devices.c | |||
@@ -195,7 +195,7 @@ static struct mxc_gpio_port mxc_gpio_ports[] = { | |||
195 | }, | 195 | }, |
196 | }; | 196 | }; |
197 | 197 | ||
198 | int __init mxc_register_gpios(void) | 198 | int __init imx51_register_gpios(void) |
199 | { | 199 | { |
200 | return mxc_gpio_init(mxc_gpio_ports, ARRAY_SIZE(mxc_gpio_ports)); | 200 | return mxc_gpio_init(mxc_gpio_ports, ARRAY_SIZE(mxc_gpio_ports)); |
201 | } | 201 | } |
diff --git a/arch/arm/mach-mx5/mm.c b/arch/arm/mach-mx5/mm.c index b7677ef80cc4..2f79722508cf 100644 --- a/arch/arm/mach-mx5/mm.c +++ b/arch/arm/mach-mx5/mm.c | |||
@@ -65,6 +65,8 @@ void __init mx51_map_io(void) | |||
65 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | 65 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
66 | } | 66 | } |
67 | 67 | ||
68 | int imx51_register_gpios(void); | ||
69 | |||
68 | void __init mx51_init_irq(void) | 70 | void __init mx51_init_irq(void) |
69 | { | 71 | { |
70 | unsigned long tzic_addr; | 72 | unsigned long tzic_addr; |
@@ -79,5 +81,6 @@ void __init mx51_init_irq(void) | |||
79 | if (!tzic_virt) | 81 | if (!tzic_virt) |
80 | panic("unable to map TZIC interrupt controller\n"); | 82 | panic("unable to map TZIC interrupt controller\n"); |
81 | 83 | ||
84 | imx51_register_gpios(); | ||
82 | tzic_init_irq(tzic_virt); | 85 | tzic_init_irq(tzic_virt); |
83 | } | 86 | } |
diff --git a/arch/arm/mach-mxc91231/devices.c b/arch/arm/mach-mxc91231/devices.c index 353bd977b393..027af4f0d18a 100644 --- a/arch/arm/mach-mxc91231/devices.c +++ b/arch/arm/mach-mxc91231/devices.c | |||
@@ -135,7 +135,7 @@ static struct mxc_gpio_port mxc_gpio_ports[] = { | |||
135 | }, | 135 | }, |
136 | }; | 136 | }; |
137 | 137 | ||
138 | int __init mxc_register_gpios(void) | 138 | int __init mxc91231_register_gpios(void) |
139 | { | 139 | { |
140 | return mxc_gpio_init(mxc_gpio_ports, ARRAY_SIZE(mxc_gpio_ports)); | 140 | return mxc_gpio_init(mxc_gpio_ports, ARRAY_SIZE(mxc_gpio_ports)); |
141 | } | 141 | } |
diff --git a/arch/arm/mach-mxc91231/mm.c b/arch/arm/mach-mxc91231/mm.c index 6becda3ff331..1f23c743ae65 100644 --- a/arch/arm/mach-mxc91231/mm.c +++ b/arch/arm/mach-mxc91231/mm.c | |||
@@ -88,7 +88,10 @@ void __init mxc91231_map_io(void) | |||
88 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | 88 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
89 | } | 89 | } |
90 | 90 | ||
91 | int mxc91231_register_gpios(void); | ||
92 | |||
91 | void __init mxc91231_init_irq(void) | 93 | void __init mxc91231_init_irq(void) |
92 | { | 94 | { |
95 | mxc91231_register_gpios(); | ||
93 | mxc_init_irq(MXC91231_IO_ADDRESS(MXC91231_AVIC_BASE_ADDR)); | 96 | mxc_init_irq(MXC91231_IO_ADDRESS(MXC91231_AVIC_BASE_ADDR)); |
94 | } | 97 | } |
diff --git a/arch/arm/plat-mxc/irq.c b/arch/arm/plat-mxc/irq.c index 778ddfe57d89..7331f2ace5fe 100644 --- a/arch/arm/plat-mxc/irq.c +++ b/arch/arm/plat-mxc/irq.c | |||
@@ -142,9 +142,6 @@ void __init mxc_init_irq(void __iomem *irqbase) | |||
142 | for (i = 0; i < 8; i++) | 142 | for (i = 0; i < 8; i++) |
143 | __raw_writel(0, avic_base + AVIC_NIPRIORITY(i)); | 143 | __raw_writel(0, avic_base + AVIC_NIPRIORITY(i)); |
144 | 144 | ||
145 | /* init architectures chained interrupt handler */ | ||
146 | mxc_register_gpios(); | ||
147 | |||
148 | #ifdef CONFIG_FIQ | 145 | #ifdef CONFIG_FIQ |
149 | /* Initialize FIQ */ | 146 | /* Initialize FIQ */ |
150 | init_FIQ(); | 147 | init_FIQ(); |
diff --git a/arch/arm/plat-mxc/tzic.c b/arch/arm/plat-mxc/tzic.c index 9b86d2a60d43..b3da9aad4295 100644 --- a/arch/arm/plat-mxc/tzic.c +++ b/arch/arm/plat-mxc/tzic.c | |||
@@ -145,8 +145,6 @@ void __init tzic_init_irq(void __iomem *irqbase) | |||
145 | set_irq_handler(i, handle_level_irq); | 145 | set_irq_handler(i, handle_level_irq); |
146 | set_irq_flags(i, IRQF_VALID); | 146 | set_irq_flags(i, IRQF_VALID); |
147 | } | 147 | } |
148 | mxc_register_gpios(); | ||
149 | |||
150 | pr_info("TrustZone Interrupt Controller (TZIC) initialized\n"); | 148 | pr_info("TrustZone Interrupt Controller (TZIC) initialized\n"); |
151 | } | 149 | } |
152 | 150 | ||