Commit 84659ab5 authored by Jason Wang's avatar Jason Wang Committed by Sascha Hauer

imx: move gpio init after to irq init

The commit 9a763bfb "get rid of mxc_gpio_init" changed gpio_init
and irq_init sequence. Usually we will call set_irq_chained_handler
in gpio_init functions, this should be called after the irq_init
called, otherwise the chained irq can't get propoer irq_chip and this
irq will remain masked even we called set_irq_chained_handler.
Signed-off-by: default avatarJason Wang <jason77.wang@gmail.com>
Tested-by: default avatarEric Bénard <eric@eukrea.com>
Signed-off-by: default avatarSascha Hauer <s.hauer@pengutronix.de>
parent 95afd090
...@@ -45,6 +45,6 @@ int imx1_register_gpios(void); ...@@ -45,6 +45,6 @@ int imx1_register_gpios(void);
void __init mx1_init_irq(void) void __init mx1_init_irq(void)
{ {
imx1_register_gpios();
mxc_init_irq(MX1_IO_ADDRESS(MX1_AVIC_BASE_ADDR)); mxc_init_irq(MX1_IO_ADDRESS(MX1_AVIC_BASE_ADDR));
imx1_register_gpios();
} }
...@@ -81,6 +81,6 @@ int imx21_register_gpios(void); ...@@ -81,6 +81,6 @@ int imx21_register_gpios(void);
void __init mx21_init_irq(void) void __init mx21_init_irq(void)
{ {
imx21_register_gpios();
mxc_init_irq(MX21_IO_ADDRESS(MX21_AVIC_BASE_ADDR)); mxc_init_irq(MX21_IO_ADDRESS(MX21_AVIC_BASE_ADDR));
imx21_register_gpios();
} }
...@@ -81,6 +81,6 @@ int imx27_register_gpios(void); ...@@ -81,6 +81,6 @@ int imx27_register_gpios(void);
void __init mx27_init_irq(void) void __init mx27_init_irq(void)
{ {
imx27_register_gpios();
mxc_init_irq(MX27_IO_ADDRESS(MX27_AVIC_BASE_ADDR)); mxc_init_irq(MX27_IO_ADDRESS(MX27_AVIC_BASE_ADDR));
imx27_register_gpios();
} }
...@@ -69,7 +69,7 @@ int imx25_register_gpios(void); ...@@ -69,7 +69,7 @@ int imx25_register_gpios(void);
void __init mx25_init_irq(void) void __init mx25_init_irq(void)
{ {
imx25_register_gpios();
mxc_init_irq((void __iomem *)MX25_AVIC_BASE_ADDR_VIRT); mxc_init_irq((void __iomem *)MX25_AVIC_BASE_ADDR_VIRT);
imx25_register_gpios();
} }
...@@ -97,8 +97,8 @@ int imx3x_register_gpios(void); ...@@ -97,8 +97,8 @@ int imx3x_register_gpios(void);
void __init mx31_init_irq(void) void __init mx31_init_irq(void)
{ {
imx3x_register_gpios();
mxc_init_irq(IO_ADDRESS(AVIC_BASE_ADDR)); mxc_init_irq(IO_ADDRESS(AVIC_BASE_ADDR));
imx3x_register_gpios();
} }
void __init mx35_init_irq(void) void __init mx35_init_irq(void)
......
...@@ -81,6 +81,6 @@ void __init mx51_init_irq(void) ...@@ -81,6 +81,6 @@ void __init mx51_init_irq(void)
if (!tzic_virt) if (!tzic_virt)
panic("unable to map TZIC interrupt controller\n"); panic("unable to map TZIC interrupt controller\n");
imx51_register_gpios();
tzic_init_irq(tzic_virt); tzic_init_irq(tzic_virt);
imx51_register_gpios();
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment