All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] coresight: trbe: Add ISB after TRBLIMITR write
@ 2025-06-09 10:19 James Clark
  2025-06-09 10:28 ` Yeoreum Yun
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: James Clark @ 2025-06-09 10:19 UTC (permalink / raw)
  To: Suzuki K Poulose, Mike Leach, Alexander Shishkin, Marc Zyngier
  Cc: coresight, linux-arm-kernel, linux-kernel, James Clark

DEN0154 states that hardware will be allowed to ignore writes to TRB*
registers while the trace buffer is enabled. Add an ISB to ensure that
it's disabled before clearing the other registers.

This is purely defensive because it's expected that arm_trbe_disable()
would be called before teardown which has the required ISB.

Fixes: a2b579c41fe9 ("coresight: trbe: Remove redundant disable call")
Signed-off-by: James Clark <james.clark@linaro.org>
---
 drivers/hwtracing/coresight/coresight-trbe.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/hwtracing/coresight/coresight-trbe.c b/drivers/hwtracing/coresight/coresight-trbe.c
index 8267dd1a2130..10f3fb401edf 100644
--- a/drivers/hwtracing/coresight/coresight-trbe.c
+++ b/drivers/hwtracing/coresight/coresight-trbe.c
@@ -257,6 +257,7 @@ static void trbe_drain_and_disable_local(struct trbe_cpudata *cpudata)
 static void trbe_reset_local(struct trbe_cpudata *cpudata)
 {
 	write_sysreg_s(0, SYS_TRBLIMITR_EL1);
+	isb();
 	trbe_drain_buffer();
 	write_sysreg_s(0, SYS_TRBPTR_EL1);
 	write_sysreg_s(0, SYS_TRBBASER_EL1);

---
base-commit: 19272b37aa4f83ca52bdf9c16d5d81bdd1354494
change-id: 20250609-james-cs-trblimitr-isb-523f20d874d6

Best regards,
-- 
James Clark <james.clark@linaro.org>



^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-07-09 11:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-09 10:19 [PATCH] coresight: trbe: Add ISB after TRBLIMITR write James Clark
2025-06-09 10:28 ` Yeoreum Yun
2025-06-09 11:14 ` Leo Yan
2025-06-10  9:40 ` Anshuman Khandual
2025-07-09 10:02 ` Suzuki K Poulose

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.