diff options
author | Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de> | 2007-09-30 15:36:33 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2007-10-12 18:43:41 -0400 |
commit | 361c7ad607bc0e84ef0fef8c3f11c47b33c06e41 (patch) | |
tree | eb4d73ce8fec23d402ce5da05f3394ada0dbb9ed /arch/arm/mach-ns9xxx/irq.c | |
parent | c54ecb2481d464d50520ce60cf36011b68d1e89a (diff) |
[ARM] 4595/1: ns9xxx: define registers as void __iomem * instead of volatile u32
As a consequence registers are now accessed with __raw_{read,write}[bl].
Signed-off-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-ns9xxx/irq.c')
-rw-r--r-- | arch/arm/mach-ns9xxx/irq.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/arch/arm/mach-ns9xxx/irq.c b/arch/arm/mach-ns9xxx/irq.c index 24d424e10e4c..00001b874e97 100644 --- a/arch/arm/mach-ns9xxx/irq.c +++ b/arch/arm/mach-ns9xxx/irq.c | |||
@@ -9,6 +9,7 @@ | |||
9 | * the Free Software Foundation. | 9 | * the Free Software Foundation. |
10 | */ | 10 | */ |
11 | #include <linux/interrupt.h> | 11 | #include <linux/interrupt.h> |
12 | #include <asm/io.h> | ||
12 | #include <asm/mach/irq.h> | 13 | #include <asm/mach/irq.h> |
13 | #include <asm/mach-types.h> | 14 | #include <asm/mach-types.h> |
14 | #include <asm/arch-ns9xxx/regs-sys.h> | 15 | #include <asm/arch-ns9xxx/regs-sys.h> |
@@ -20,12 +21,14 @@ | |||
20 | static void ns9xxx_mask_irq(unsigned int irq) | 21 | static void ns9xxx_mask_irq(unsigned int irq) |
21 | { | 22 | { |
22 | /* XXX: better use cpp symbols */ | 23 | /* XXX: better use cpp symbols */ |
23 | SYS_IC(irq / 4) &= ~(1 << (7 + 8 * (3 - (irq & 3)))); | 24 | u32 ic = __raw_readl(SYS_IC(irq / 4)); |
25 | ic &= ~(1 << (7 + 8 * (3 - (irq & 3)))); | ||
26 | __raw_writel(ic, SYS_IC(irq / 4)); | ||
24 | } | 27 | } |
25 | 28 | ||
26 | static void ns9xxx_ack_irq(unsigned int irq) | 29 | static void ns9xxx_ack_irq(unsigned int irq) |
27 | { | 30 | { |
28 | SYS_ISRADDR = 0; | 31 | __raw_writel(0, SYS_ISRADDR); |
29 | } | 32 | } |
30 | 33 | ||
31 | static void ns9xxx_maskack_irq(unsigned int irq) | 34 | static void ns9xxx_maskack_irq(unsigned int irq) |
@@ -37,7 +40,9 @@ static void ns9xxx_maskack_irq(unsigned int irq) | |||
37 | static void ns9xxx_unmask_irq(unsigned int irq) | 40 | static void ns9xxx_unmask_irq(unsigned int irq) |
38 | { | 41 | { |
39 | /* XXX: better use cpp symbols */ | 42 | /* XXX: better use cpp symbols */ |
40 | SYS_IC(irq / 4) |= 1 << (7 + 8 * (3 - (irq & 3))); | 43 | u32 ic = __raw_readl(SYS_IC(irq / 4)); |
44 | ic |= 1 << (7 + 8 * (3 - (irq & 3))); | ||
45 | __raw_writel(ic, SYS_IC(irq / 4)); | ||
41 | } | 46 | } |
42 | 47 | ||
43 | static struct irq_chip ns9xxx_chip = { | 48 | static struct irq_chip ns9xxx_chip = { |
@@ -53,14 +58,14 @@ void __init ns9xxx_init_irq(void) | |||
53 | 58 | ||
54 | /* disable all IRQs */ | 59 | /* disable all IRQs */ |
55 | for (i = 0; i < 8; ++i) | 60 | for (i = 0; i < 8; ++i) |
56 | SYS_IC(i) = (4 * i) << 24 | (4 * i + 1) << 16 | | 61 | __raw_writel((4 * i) << 24 | (4 * i + 1) << 16 | |
57 | (4 * i + 2) << 8 | (4 * i + 3); | 62 | (4 * i + 2) << 8 | (4 * i + 3), SYS_IC(i)); |
58 | 63 | ||
59 | /* simple interrupt prio table: | 64 | /* simple interrupt prio table: |
60 | * prio(x) < prio(y) <=> x < y | 65 | * prio(x) < prio(y) <=> x < y |
61 | */ | 66 | */ |
62 | for (i = 0; i < 32; ++i) | 67 | for (i = 0; i < 32; ++i) |
63 | SYS_IVA(i) = i; | 68 | __raw_writel(i, SYS_IVA(i)); |
64 | 69 | ||
65 | for (i = IRQ_WATCHDOG; i <= IRQ_EXT3; ++i) { | 70 | for (i = IRQ_WATCHDOG; i <= IRQ_EXT3; ++i) { |
66 | set_irq_chip(i, &ns9xxx_chip); | 71 | set_irq_chip(i, &ns9xxx_chip); |