diff options
author | Marc Zyngier <marc.zyngier@arm.com> | 2018-07-27 11:03:31 -0400 |
---|---|---|
committer | Marc Zyngier <marc.zyngier@arm.com> | 2018-10-02 05:37:37 -0400 |
commit | f842ca8e9c8a80d07f5589536311250d7d6018f9 (patch) | |
tree | 3d0e0854d5f7b568a1b037efcbf0dc0a75ab1c51 /drivers/irqchip | |
parent | c6e2ccb66d0c3b4fffc59932585e9f709ad59003 (diff) |
irqchip/gic-v3-its: Check that all RDs have the same property table
If booting with LPIs enabled, all the redistributors must have the
exact same property table. No ifs, no buts.
Tested-by: Jeremy Linton <jeremy.linton@arm.com>
Tested-by: Bhupesh Sharma <bhsharma@redhat.com>
Tested-by: Lei Zhang <zhang.lei@jp.fujitsu.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'drivers/irqchip')
-rw-r--r-- | drivers/irqchip/irq-gic-v3-its.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c index 83d5573f56e9..828af1a68b8e 100644 --- a/drivers/irqchip/irq-gic-v3-its.c +++ b/drivers/irqchip/irq-gic-v3-its.c | |||
@@ -2029,6 +2029,15 @@ static void its_cpu_init_lpis(void) | |||
2029 | val = readl_relaxed(rbase + GICR_CTLR); | 2029 | val = readl_relaxed(rbase + GICR_CTLR); |
2030 | if ((gic_rdists->flags & RDIST_FLAGS_RD_TABLES_PREALLOCATED) && | 2030 | if ((gic_rdists->flags & RDIST_FLAGS_RD_TABLES_PREALLOCATED) && |
2031 | (val & GICR_CTLR_ENABLE_LPIS)) { | 2031 | (val & GICR_CTLR_ENABLE_LPIS)) { |
2032 | /* | ||
2033 | * Check that we get the same property table on all | ||
2034 | * RDs. If we don't, this is hopeless. | ||
2035 | */ | ||
2036 | paddr = gicr_read_propbaser(rbase + GICR_PROPBASER); | ||
2037 | paddr &= GENMASK_ULL(51, 12); | ||
2038 | if (WARN_ON(gic_rdists->prop_table_pa != paddr)) | ||
2039 | add_taint(TAINT_CRAP, LOCKDEP_STILL_OK); | ||
2040 | |||
2032 | paddr = gicr_read_pendbaser(rbase + GICR_PENDBASER); | 2041 | paddr = gicr_read_pendbaser(rbase + GICR_PENDBASER); |
2033 | paddr &= GENMASK_ULL(51, 16); | 2042 | paddr &= GENMASK_ULL(51, 16); |
2034 | 2043 | ||