diff options
author | Alexander Couzens <lynxis@fe80.eu> | 2015-09-19 00:26:20 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2015-09-22 13:07:11 -0400 |
commit | 19446da415e0f01d56364b700fe984cda78bca50 (patch) | |
tree | e047d380464aa5742de678d583ca4e5463c00ce7 | |
parent | 84dedd71cf3bc61cc65ca43a48f7252344a1bb68 (diff) |
MIPS: ATH79: Add irq chip ar7240-misc-intc
The ar7240 misc irq chip use ack handler
instead of ack_mask handler. All new ath79 chips use
the ar7240 misc irq chip
Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
Acked-by: Alban Bedel <albeu@free.fr>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-mips@linux-mips.org
Cc: Rob Herring <robh+dt@kernel.org>
Cc: Pawel Moll <pawel.moll@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Ian Campbell <ijc+devicetree@hellion.org.uk>
Cc: Kumar Gala <galak@codeaurora.org>
Cc: devicetree@vger.kernel.org
Cc: Jason Cooper <jason@lakedaemon.net>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/11164/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
-rw-r--r-- | Documentation/devicetree/bindings/interrupt-controller/qca,ath79-misc-intc.txt | 20 | ||||
-rw-r--r-- | arch/mips/ath79/irq.c | 10 |
2 files changed, 28 insertions, 2 deletions
diff --git a/Documentation/devicetree/bindings/interrupt-controller/qca,ath79-misc-intc.txt b/Documentation/devicetree/bindings/interrupt-controller/qca,ath79-misc-intc.txt index 391717a68f3b..ec96b1f01478 100644 --- a/Documentation/devicetree/bindings/interrupt-controller/qca,ath79-misc-intc.txt +++ b/Documentation/devicetree/bindings/interrupt-controller/qca,ath79-misc-intc.txt | |||
@@ -4,8 +4,8 @@ The MISC interrupt controller is a secondary controller for lower priority | |||
4 | interrupt. | 4 | interrupt. |
5 | 5 | ||
6 | Required Properties: | 6 | Required Properties: |
7 | - compatible: has to be "qca,<soctype>-cpu-intc", "qca,ar7100-misc-intc" | 7 | - compatible: has to be "qca,<soctype>-cpu-intc", "qca,ar7100-misc-intc" or |
8 | as fallback | 8 | "qca,<soctype>-cpu-intc", "qca,ar7240-misc-intc" |
9 | - reg: Base address and size of the controllers memory area | 9 | - reg: Base address and size of the controllers memory area |
10 | - interrupt-parent: phandle of the parent interrupt controller. | 10 | - interrupt-parent: phandle of the parent interrupt controller. |
11 | - interrupts: Interrupt specifier for the controllers interrupt. | 11 | - interrupts: Interrupt specifier for the controllers interrupt. |
@@ -13,6 +13,9 @@ Required Properties: | |||
13 | - #interrupt-cells : Specifies the number of cells needed to encode interrupt | 13 | - #interrupt-cells : Specifies the number of cells needed to encode interrupt |
14 | source, should be 1 | 14 | source, should be 1 |
15 | 15 | ||
16 | Compatible fallback depends on the SoC. Use ar7100 for ar71xx and ar913x, | ||
17 | use ar7240 for all other SoCs. | ||
18 | |||
16 | Please refer to interrupts.txt in this directory for details of the common | 19 | Please refer to interrupts.txt in this directory for details of the common |
17 | Interrupt Controllers bindings used by client devices. | 20 | Interrupt Controllers bindings used by client devices. |
18 | 21 | ||
@@ -28,3 +31,16 @@ Example: | |||
28 | interrupt-controller; | 31 | interrupt-controller; |
29 | #interrupt-cells = <1>; | 32 | #interrupt-cells = <1>; |
30 | }; | 33 | }; |
34 | |||
35 | Another example: | ||
36 | |||
37 | interrupt-controller@18060010 { | ||
38 | compatible = "qca,ar9331-misc-intc", qca,ar7240-misc-intc"; | ||
39 | reg = <0x18060010 0x4>; | ||
40 | |||
41 | interrupt-parent = <&cpuintc>; | ||
42 | interrupts = <6>; | ||
43 | |||
44 | interrupt-controller; | ||
45 | #interrupt-cells = <1>; | ||
46 | }; | ||
diff --git a/arch/mips/ath79/irq.c b/arch/mips/ath79/irq.c index bf1651cc7e64..eeb3953ed8ac 100644 --- a/arch/mips/ath79/irq.c +++ b/arch/mips/ath79/irq.c | |||
@@ -304,6 +304,16 @@ static int __init ar7100_misc_intc_of_init( | |||
304 | IRQCHIP_DECLARE(ar7100_misc_intc, "qca,ar7100-misc-intc", | 304 | IRQCHIP_DECLARE(ar7100_misc_intc, "qca,ar7100-misc-intc", |
305 | ar7100_misc_intc_of_init); | 305 | ar7100_misc_intc_of_init); |
306 | 306 | ||
307 | static int __init ar7240_misc_intc_of_init( | ||
308 | struct device_node *node, struct device_node *parent) | ||
309 | { | ||
310 | ath79_misc_irq_chip.irq_ack = ar724x_misc_irq_ack; | ||
311 | return ath79_misc_intc_of_init(node, parent); | ||
312 | } | ||
313 | |||
314 | IRQCHIP_DECLARE(ar7240_misc_intc, "qca,ar7240-misc-intc", | ||
315 | ar7240_misc_intc_of_init); | ||
316 | |||
307 | static int __init ar79_cpu_intc_of_init( | 317 | static int __init ar79_cpu_intc_of_init( |
308 | struct device_node *node, struct device_node *parent) | 318 | struct device_node *node, struct device_node *parent) |
309 | { | 319 | { |