Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1602672 > unrolled thread

[PATCH 2/2] irqchip/gic-v3-its: always check for cacheability attributes

Started byAndre Przywara <andre.przywara@arm.com>
First post2017-03-16 18:10 +0100
Last post2017-03-16 18:10 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 2/2] irqchip/gic-v3-its: always check for cacheability attributes Andre Przywara <andre.przywara@arm.com> - 2017-03-16 18:10 +0100

#1602672 — [PATCH 2/2] irqchip/gic-v3-its: always check for cacheability attributes

FromAndre Przywara <andre.przywara@arm.com>
Date2017-03-16 18:10 +0100
Subject[PATCH 2/2] irqchip/gic-v3-its: always check for cacheability attributes
Message-ID<tlH4t-1sh-25@gated-at.bofh.it>
Currently we only enable cache flushing if the redistributor denied
our shareability attribute, because we turn off cacheability in this
case.
But if it would just turn down our cacheability request, we would miss
setting the flag.

Re-check the cacheability attribute as reported back by the
redistributor to make sure we flush properly if needed.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
 drivers/irqchip/irq-gic-v3-its.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
index b777c57..5cd4d58 100644
--- a/drivers/irqchip/irq-gic-v3-its.c
+++ b/drivers/irqchip/irq-gic-v3-its.c
@@ -1156,7 +1156,12 @@ static int its_cpu_init_lpis(void)
 				 GICR_PROPBASER_CACHEABILITY_MASK);
 			val |= GICR_PROPBASER_nC;
 			gicr_write_propbaser(val, rbase + GICR_PROPBASER);
+			tmp = gicr_read_propbaser(rbase + GICR_PROPBASER);
 		}
+	}
+
+	if (((tmp & GICR_PROPBASER_CACHEABILITY_MASK) == GICR_PROPBASER_nC) ||
+	    ((tmp & GICR_PROPBASER_CACHEABILITY_MASK) == GICR_PROPBASER_nCnB)) {
 		pr_info_once("GIC: using cache flushing for LPI property table\n");
 		gic_rdists->flags |= RDIST_FLAGS_PROPBASE_NEEDS_FLUSHING;
 	}
-- 
2.9.0

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web