summaryrefslogtreecommitdiff
path: root/arch/arm/mach-shmobile/pfc-sh73a0.c
diff options
context:
space:
mode:
authorMagnus Damm <damm@opensource.se>2011-10-12 16:21:42 +0900
committerPaul Mundt <lethal@linux-sh.org>2011-11-05 01:02:51 +0900
commita1993055efcc14fd6d213b936d28a41ea52e1d3d (patch)
tree5284a00f273605d79cc9367594605a44ac1729ed /arch/arm/mach-shmobile/pfc-sh73a0.c
parentda5713ef03aba15761eeeade4f4938e5db98b1e2 (diff)
ARM: mach-shmobile: Use common INTC IRQ code on sh73a0
Improve IRQ triggering support by making use of the macro INTC_IRQ_PINS_32() for INTCA on sh73a0. Unfortunately it is not as easy as just using the macro as-is, we need to do mask and unmaks in the GIC but configure other bits and ack in INTCA. Update GPIO IRQ mappings while at it. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/arm/mach-shmobile/pfc-sh73a0.c')
-rw-r--r--arch/arm/mach-shmobile/pfc-sh73a0.c68
1 files changed, 35 insertions, 33 deletions
diff --git a/arch/arm/mach-shmobile/pfc-sh73a0.c b/arch/arm/mach-shmobile/pfc-sh73a0.c
index 57322c9fd9b6..5abe02fbd6b9 100644
--- a/arch/arm/mach-shmobile/pfc-sh73a0.c
+++ b/arch/arm/mach-shmobile/pfc-sh73a0.c
@@ -2766,41 +2766,43 @@ static struct pinmux_data_reg pinmux_data_regs[] = {
{ },
};
-#define EXT_IRQ(n) gic_spi((n) + 1) /* GIC SPI starting from 1 for IRQ0 */
+/* IRQ pins through INTCS with IRQ0->15 from 0x200 and IRQ16-31 from 0x3200 */
+#define EXT_IRQ16L(n) intcs_evt2irq(0x200 + ((n) << 5))
+#define EXT_IRQ16H(n) intcs_evt2irq(0x3200 + ((n - 16) << 5))
static struct pinmux_irq pinmux_irqs[] = {
- PINMUX_IRQ(EXT_IRQ(19), PORT9_FN0),
- PINMUX_IRQ(EXT_IRQ(1), PORT10_FN0),
- PINMUX_IRQ(EXT_IRQ(0), PORT11_FN0),
- PINMUX_IRQ(EXT_IRQ(18), PORT13_FN0),
- PINMUX_IRQ(EXT_IRQ(20), PORT14_FN0),
- PINMUX_IRQ(EXT_IRQ(21), PORT15_FN0),
- PINMUX_IRQ(EXT_IRQ(31), PORT26_FN0),
- PINMUX_IRQ(EXT_IRQ(30), PORT27_FN0),
- PINMUX_IRQ(EXT_IRQ(29), PORT28_FN0),
- PINMUX_IRQ(EXT_IRQ(22), PORT40_FN0),
- PINMUX_IRQ(EXT_IRQ(23), PORT53_FN0),
- PINMUX_IRQ(EXT_IRQ(10), PORT54_FN0),
- PINMUX_IRQ(EXT_IRQ(9), PORT56_FN0),
- PINMUX_IRQ(EXT_IRQ(26), PORT115_FN0),
- PINMUX_IRQ(EXT_IRQ(27), PORT116_FN0),
- PINMUX_IRQ(EXT_IRQ(28), PORT117_FN0),
- PINMUX_IRQ(EXT_IRQ(24), PORT118_FN0),
- PINMUX_IRQ(EXT_IRQ(6), PORT147_FN0),
- PINMUX_IRQ(EXT_IRQ(2), PORT149_FN0),
- PINMUX_IRQ(EXT_IRQ(7), PORT150_FN0),
- PINMUX_IRQ(EXT_IRQ(12), PORT156_FN0),
- PINMUX_IRQ(EXT_IRQ(4), PORT159_FN0),
- PINMUX_IRQ(EXT_IRQ(25), PORT164_FN0),
- PINMUX_IRQ(EXT_IRQ(8), PORT223_FN0),
- PINMUX_IRQ(EXT_IRQ(3), PORT224_FN0),
- PINMUX_IRQ(EXT_IRQ(5), PORT227_FN0),
- PINMUX_IRQ(EXT_IRQ(17), PORT234_FN0),
- PINMUX_IRQ(EXT_IRQ(11), PORT238_FN0),
- PINMUX_IRQ(EXT_IRQ(13), PORT239_FN0),
- PINMUX_IRQ(EXT_IRQ(16), PORT249_FN0),
- PINMUX_IRQ(EXT_IRQ(14), PORT251_FN0),
- PINMUX_IRQ(EXT_IRQ(9), PORT308_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(19), PORT9_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(1), PORT10_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(0), PORT11_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(18), PORT13_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(20), PORT14_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(21), PORT15_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(31), PORT26_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(30), PORT27_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(29), PORT28_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(22), PORT40_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(23), PORT53_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(10), PORT54_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(9), PORT56_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(26), PORT115_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(27), PORT116_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(28), PORT117_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(24), PORT118_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(6), PORT147_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(2), PORT149_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(7), PORT150_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(12), PORT156_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(4), PORT159_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(25), PORT164_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(8), PORT223_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(3), PORT224_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(5), PORT227_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(17), PORT234_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(11), PORT238_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(13), PORT239_FN0),
+ PINMUX_IRQ(EXT_IRQ16H(16), PORT249_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(14), PORT251_FN0),
+ PINMUX_IRQ(EXT_IRQ16L(9), PORT308_FN0),
};
static struct pinmux_info sh73a0_pinmux_info = {