Skip to content

Commit 93cc122

Browse files
committed
Merge branch 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull irq updates from Thomas Gleixner: "The interrupt subsystem delivers this time: - Refactoring of the GIC-V3 driver to prepare for the GIC-V4 support - Initial GIC-V4 support - Consolidation of the FSL MSI support - Utilize the effective affinity interface in various ARM irqchip drivers - Yet another interrupt chip driver (UniPhier AIDET) - Bulk conversion of the irq chip driver to use %pOF - The usual small fixes and improvements all over the place" * 'irq-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (77 commits) irqchip/ls-scfg-msi: Add MSI affinity support irqchip/ls-scfg-msi: Add LS1043a v1.1 MSI support irqchip/ls-scfg-msi: Add LS1046a MSI support arm64: dts: ls1046a: Add MSI dts node arm64: dts: ls1043a: Share all MSIs arm: dts: ls1021a: Share all MSIs arm64: dts: ls1043a: Fix typo of MSI compatible string arm: dts: ls1021a: Fix typo of MSI compatible string irqchip/ls-scfg-msi: Fix typo of MSI compatible strings irqchip/irq-bcm7120-l2: Use correct I/O accessors for irq_fwd_mask irqchip/mmp: Make mmp_intc_conf const irqchip/gic: Make irq_chip const irqchip/gic-v3: Advertise GICv4 support to KVM irqchip/gic-v4: Enable low-level GICv4 operations irqchip/gic-v4: Add some basic documentation irqchip/gic-v4: Add VLPI configuration interface irqchip/gic-v4: Add VPE command interface irqchip/gic-v4: Add per-VM VPE domain creation irqchip/gic-v3-its: Set implementation defined bit to enable VLPIs irqchip/gic-v3-its: Allow doorbell interrupts to be injected/cleared ...
2 parents dd90ccc + 9fbd7fd commit 93cc122

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+3188
-299
lines changed

Documentation/devicetree/bindings/interrupt-controller/fsl,ls-scfg-msi.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ Required properties:
44

55
- compatible: should be "fsl,<soc-name>-msi" to identify
66
Layerscape PCIe MSI controller block such as:
7-
"fsl,1s1021a-msi"
8-
"fsl,1s1043a-msi"
7+
"fsl,ls1021a-msi"
8+
"fsl,ls1043a-msi"
9+
"fsl,ls1046a-msi"
10+
"fsl,ls1043a-v1.1-msi"
911
- msi-controller: indicates that this is a PCIe MSI controller node
1012
- reg: physical base address of the controller and length of memory mapped.
1113
- interrupts: an interrupt to the parent interrupt controller.
@@ -23,7 +25,7 @@ MSI controller node
2325
Examples:
2426

2527
msi1: msi-controller@1571000 {
26-
compatible = "fsl,1s1043a-msi";
28+
compatible = "fsl,ls1043a-msi";
2729
reg = <0x0 0x1571000 0x0 0x8>,
2830
msi-controller;
2931
interrupts = <0 116 0x4>;
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
UniPhier AIDET
2+
3+
UniPhier AIDET (ARM Interrupt Detector) is an add-on block for ARM GIC (Generic
4+
Interrupt Controller). GIC itself can handle only high level and rising edge
5+
interrupts. The AIDET provides logic inverter to support low level and falling
6+
edge interrupts.
7+
8+
Required properties:
9+
- compatible: Should be one of the following:
10+
"socionext,uniphier-ld4-aidet" - for LD4 SoC
11+
"socionext,uniphier-pro4-aidet" - for Pro4 SoC
12+
"socionext,uniphier-sld8-aidet" - for sLD8 SoC
13+
"socionext,uniphier-pro5-aidet" - for Pro5 SoC
14+
"socionext,uniphier-pxs2-aidet" - for PXs2/LD6b SoC
15+
"socionext,uniphier-ld11-aidet" - for LD11 SoC
16+
"socionext,uniphier-ld20-aidet" - for LD20 SoC
17+
"socionext,uniphier-pxs3-aidet" - for PXs3 SoC
18+
- reg: Specifies offset and length of the register set for the device.
19+
- interrupt-controller: Identifies the node as an interrupt controller
20+
- #interrupt-cells : Specifies the number of cells needed to encode an interrupt
21+
source. The value should be 2. The first cell defines the interrupt number
22+
(corresponds to the SPI interrupt number of GIC). The second cell specifies
23+
the trigger type as defined in interrupts.txt in this directory.
24+
25+
Example:
26+
27+
aidet: aidet@5fc20000 {
28+
compatible = "socionext,uniphier-pro4-aidet";
29+
reg = <0x5fc20000 0x200>;
30+
interrupt-controller;
31+
#interrupt-cells = <2>;
32+
};

Documentation/driver-model/devres.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,7 @@ IRQ
312312
devm_irq_alloc_descs_from()
313313
devm_irq_alloc_generic_chip()
314314
devm_irq_setup_generic_chip()
315+
devm_irq_sim_init()
315316

316317
LED
317318
devm_led_classdev_register()

MAINTAINERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1993,6 +1993,7 @@ F: arch/arm64/boot/dts/socionext/
19931993
F: drivers/bus/uniphier-system-bus.c
19941994
F: drivers/clk/uniphier/
19951995
F: drivers/i2c/busses/i2c-uniphier*
1996+
F: drivers/irqchip/irq-uniphier-aidet.c
19961997
F: drivers/pinctrl/uniphier/
19971998
F: drivers/reset/reset-uniphier.c
19981999
F: drivers/tty/serial/8250/8250_uniphier.c

arch/arm/boot/dts/ls1021a.dtsi

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,14 +129,14 @@
129129
};
130130

131131
msi1: msi-controller@1570e00 {
132-
compatible = "fsl,1s1021a-msi";
132+
compatible = "fsl,ls1021a-msi";
133133
reg = <0x0 0x1570e00 0x0 0x8>;
134134
msi-controller;
135135
interrupts = <GIC_SPI 179 IRQ_TYPE_LEVEL_HIGH>;
136136
};
137137

138138
msi2: msi-controller@1570e08 {
139-
compatible = "fsl,1s1021a-msi";
139+
compatible = "fsl,ls1021a-msi";
140140
reg = <0x0 0x1570e08 0x0 0x8>;
141141
msi-controller;
142142
interrupts = <GIC_SPI 180 IRQ_TYPE_LEVEL_HIGH>;
@@ -699,7 +699,7 @@
699699
bus-range = <0x0 0xff>;
700700
ranges = <0x81000000 0x0 0x00000000 0x40 0x00010000 0x0 0x00010000 /* downstream I/O */
701701
0x82000000 0x0 0x40000000 0x40 0x40000000 0x0 0x40000000>; /* non-prefetchable memory */
702-
msi-parent = <&msi1>;
702+
msi-parent = <&msi1>, <&msi2>;
703703
#interrupt-cells = <1>;
704704
interrupt-map-mask = <0 0 0 7>;
705705
interrupt-map = <0000 0 0 1 &gic GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>,
@@ -722,7 +722,7 @@
722722
bus-range = <0x0 0xff>;
723723
ranges = <0x81000000 0x0 0x00000000 0x48 0x00010000 0x0 0x00010000 /* downstream I/O */
724724
0x82000000 0x0 0x40000000 0x48 0x40000000 0x0 0x40000000>; /* non-prefetchable memory */
725-
msi-parent = <&msi2>;
725+
msi-parent = <&msi1>, <&msi2>;
726726
#interrupt-cells = <1>;
727727
interrupt-map-mask = <0 0 0 7>;
728728
interrupt-map = <0000 0 0 1 &gic GIC_SPI 92 IRQ_TYPE_LEVEL_HIGH>,

arch/arm/include/asm/arch_gicv3.h

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,12 @@ static inline u64 __gic_readq_nonatomic(const volatile void __iomem *addr)
275275
#define gicr_read_pendbaser(c) __gic_readq_nonatomic(c)
276276
#define gicr_write_pendbaser(v, c) __gic_writeq_nonatomic(v, c)
277277

278+
/*
279+
* GICR_xLPIR - only the lower bits are significant
280+
*/
281+
#define gic_read_lpir(c) readl_relaxed(c)
282+
#define gic_write_lpir(v, c) writel_relaxed(lower_32_bits(v), c)
283+
278284
/*
279285
* GITS_TYPER is an ID register and doesn't need atomicity.
280286
*/
@@ -291,5 +297,33 @@ static inline u64 __gic_readq_nonatomic(const volatile void __iomem *addr)
291297
*/
292298
#define gits_write_cwriter(v, c) __gic_writeq_nonatomic(v, c)
293299

300+
/*
301+
* GITS_VPROPBASER - hi and lo bits may be accessed independently.
302+
*/
303+
#define gits_write_vpropbaser(v, c) __gic_writeq_nonatomic(v, c)
304+
305+
/*
306+
* GITS_VPENDBASER - the Valid bit must be cleared before changing
307+
* anything else.
308+
*/
309+
static inline void gits_write_vpendbaser(u64 val, void * __iomem addr)
310+
{
311+
u32 tmp;
312+
313+
tmp = readl_relaxed(addr + 4);
314+
if (tmp & (GICR_VPENDBASER_Valid >> 32)) {
315+
tmp &= ~(GICR_VPENDBASER_Valid >> 32);
316+
writel_relaxed(tmp, addr + 4);
317+
}
318+
319+
/*
320+
* Use the fact that __gic_writeq_nonatomic writes the second
321+
* half of the 64bit quantity after the first.
322+
*/
323+
__gic_writeq_nonatomic(val, addr);
324+
}
325+
326+
#define gits_read_vpendbaser(c) __gic_readq_nonatomic(c)
327+
294328
#endif /* !__ASSEMBLY__ */
295329
#endif /* !__ASM_ARCH_GICV3_H */

arch/arm/mach-hisi/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ config ARCH_HIP04
3939
select HAVE_ARM_ARCH_TIMER
4040
select MCPM if SMP
4141
select MCPM_QUAD_CLUSTER if SMP
42+
select GENERIC_IRQ_EFFECTIVE_AFF_MASK
4243
help
4344
Support for Hisilicon HiP04 SoC family
4445

arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -653,21 +653,21 @@
653653
};
654654

655655
msi1: msi-controller1@1571000 {
656-
compatible = "fsl,1s1043a-msi";
656+
compatible = "fsl,ls1043a-msi";
657657
reg = <0x0 0x1571000 0x0 0x8>;
658658
msi-controller;
659659
interrupts = <0 116 0x4>;
660660
};
661661

662662
msi2: msi-controller2@1572000 {
663-
compatible = "fsl,1s1043a-msi";
663+
compatible = "fsl,ls1043a-msi";
664664
reg = <0x0 0x1572000 0x0 0x8>;
665665
msi-controller;
666666
interrupts = <0 126 0x4>;
667667
};
668668

669669
msi3: msi-controller3@1573000 {
670-
compatible = "fsl,1s1043a-msi";
670+
compatible = "fsl,ls1043a-msi";
671671
reg = <0x0 0x1573000 0x0 0x8>;
672672
msi-controller;
673673
interrupts = <0 160 0x4>;
@@ -689,7 +689,7 @@
689689
bus-range = <0x0 0xff>;
690690
ranges = <0x81000000 0x0 0x00000000 0x40 0x00010000 0x0 0x00010000 /* downstream I/O */
691691
0x82000000 0x0 0x40000000 0x40 0x40000000 0x0 0x40000000>; /* non-prefetchable memory */
692-
msi-parent = <&msi1>;
692+
msi-parent = <&msi1>, <&msi2>, <&msi3>;
693693
#interrupt-cells = <1>;
694694
interrupt-map-mask = <0 0 0 7>;
695695
interrupt-map = <0000 0 0 1 &gic 0 110 0x4>,
@@ -714,7 +714,7 @@
714714
bus-range = <0x0 0xff>;
715715
ranges = <0x81000000 0x0 0x00000000 0x48 0x00010000 0x0 0x00010000 /* downstream I/O */
716716
0x82000000 0x0 0x40000000 0x48 0x40000000 0x0 0x40000000>; /* non-prefetchable memory */
717-
msi-parent = <&msi2>;
717+
msi-parent = <&msi1>, <&msi2>, <&msi3>;
718718
#interrupt-cells = <1>;
719719
interrupt-map-mask = <0 0 0 7>;
720720
interrupt-map = <0000 0 0 1 &gic 0 120 0x4>,
@@ -739,7 +739,7 @@
739739
bus-range = <0x0 0xff>;
740740
ranges = <0x81000000 0x0 0x00000000 0x50 0x00010000 0x0 0x00010000 /* downstream I/O */
741741
0x82000000 0x0 0x40000000 0x50 0x40000000 0x0 0x40000000>; /* non-prefetchable memory */
742-
msi-parent = <&msi3>;
742+
msi-parent = <&msi1>, <&msi2>, <&msi3>;
743743
#interrupt-cells = <1>;
744744
interrupt-map-mask = <0 0 0 7>;
745745
interrupt-map = <0000 0 0 1 &gic 0 154 0x4>,

arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -630,6 +630,37 @@
630630
interrupts = <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>;
631631
clocks = <&clockgen 4 1>;
632632
};
633+
634+
msi1: msi-controller@1580000 {
635+
compatible = "fsl,ls1046a-msi";
636+
msi-controller;
637+
reg = <0x0 0x1580000 0x0 0x10000>;
638+
interrupts = <GIC_SPI 116 IRQ_TYPE_LEVEL_HIGH>,
639+
<GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH>,
640+
<GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>,
641+
<GIC_SPI 113 IRQ_TYPE_LEVEL_HIGH>;
642+
};
643+
644+
msi2: msi-controller@1590000 {
645+
compatible = "fsl,ls1046a-msi";
646+
msi-controller;
647+
reg = <0x0 0x1590000 0x0 0x10000>;
648+
interrupts = <GIC_SPI 126 IRQ_TYPE_LEVEL_HIGH>,
649+
<GIC_SPI 121 IRQ_TYPE_LEVEL_HIGH>,
650+
<GIC_SPI 122 IRQ_TYPE_LEVEL_HIGH>,
651+
<GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>;
652+
};
653+
654+
msi3: msi-controller@15a0000 {
655+
compatible = "fsl,ls1046a-msi";
656+
msi-controller;
657+
reg = <0x0 0x15a0000 0x0 0x10000>;
658+
interrupts = <GIC_SPI 160 IRQ_TYPE_LEVEL_HIGH>,
659+
<GIC_SPI 155 IRQ_TYPE_LEVEL_HIGH>,
660+
<GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>,
661+
<GIC_SPI 157 IRQ_TYPE_LEVEL_HIGH>;
662+
};
663+
633664
};
634665

635666
reserved-memory {

arch/arm64/include/asm/arch_gicv3.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,8 @@ static inline void gic_write_bpr1(u32 val)
116116

117117
#define gic_read_typer(c) readq_relaxed(c)
118118
#define gic_write_irouter(v, c) writeq_relaxed(v, c)
119+
#define gic_read_lpir(c) readq_relaxed(c)
120+
#define gic_write_lpir(v, c) writeq_relaxed(v, c)
119121

120122
#define gic_flush_dcache_to_poc(a,l) __flush_dcache_area((a), (l))
121123

@@ -133,5 +135,10 @@ static inline void gic_write_bpr1(u32 val)
133135
#define gicr_write_pendbaser(v, c) writeq_relaxed(v, c)
134136
#define gicr_read_pendbaser(c) readq_relaxed(c)
135137

138+
#define gits_write_vpropbaser(v, c) writeq_relaxed(v, c)
139+
140+
#define gits_write_vpendbaser(v, c) writeq_relaxed(v, c)
141+
#define gits_read_vpendbaser(c) readq_relaxed(c)
142+
136143
#endif /* __ASSEMBLY__ */
137144
#endif /* __ASM_ARCH_GICV3_H */

0 commit comments

Comments
 (0)