Thread (11 messages) 11 messages, 2 authors, 2021-10-25

Re: [PATCH 1/3] irqchip/gic-v3-its: Give the percpu rdist struct its own flags field

From: Marc Zyngier <maz@kernel.org>
Date: 2021-10-23 09:10:12
Also in: linux-rt-users, lkml

On Fri, 22 Oct 2021 11:33:05 +0100,
Valentin Schneider [off-list ref] wrote:
quoted hunk ↗ jump to hunk
Later patches will require tracking some per-rdist status. Reuse the bytes
"lost" to padding within the __percpu rdist struct as a flags field, and
re-encode ->lpi_enabled within said flags.

No change in functionality intended.

Signed-off-by: Valentin Schneider <redacted>
---
 drivers/irqchip/irq-gic-v3-its.c   | 26 ++++++++++++++------------
 include/linux/irqchip/arm-gic-v3.h |  2 +-
 2 files changed, 15 insertions(+), 13 deletions(-)
diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
index eb0882d15366..a688ed5c21e8 100644
--- a/drivers/irqchip/irq-gic-v3-its.c
+++ b/drivers/irqchip/irq-gic-v3-its.c
@@ -43,8 +43,10 @@
 #define ITS_FLAGS_WORKAROUND_CAVIUM_22375	(1ULL << 1)
 #define ITS_FLAGS_WORKAROUND_CAVIUM_23144	(1ULL << 2)
 
-#define RDIST_FLAGS_PROPBASE_NEEDS_FLUSHING	(1 << 0)
-#define RDIST_FLAGS_RD_TABLES_PREALLOCATED	(1 << 1)
+#define RDISTS_FLAGS_PROPBASE_NEEDS_FLUSHING	(1 << 0)
+#define RDISTS_FLAGS_RD_TABLES_PREALLOCATED	(1 << 1)
+
+#define RDIST_FLAGS_LPI_ENABLED                 BIT(0)
Just to reduce the churn and for me not to misread things (because
RDIST/RDISTS is pretty confusing), how about leaving the original
flags as is, and name the per-RD ones like:

#define	RD_LOCAL_LPI_ENABLED	BIT(0)

?

Or something else that'd be adequately different from the original
flags?

Otherwise looks sensible.

	M.

-- 
Without deviation from the norm, progress is not possible.

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help