coresight: tmc: Don't enable TMC when it's not ready.
authorYabin Cui <yabinc@google.com>
Fri, 27 Jan 2023 23:10:01 +0000 (23:10 +0000)
committerSuzuki K Poulose <suzuki.poulose@arm.com>
Mon, 30 Jan 2023 11:45:32 +0000 (11:45 +0000)
commit669c4614236a7f78a2b693d0024cbdfa8536eb5a
treecb55e62d6c214593f8d43f74fe151067f0f372f8
parentc88a15d9dd7dfabe2a13473fd1f9c4b9cd1b62c9
coresight: tmc: Don't enable TMC when it's not ready.

If TMC ETR is enabled without being ready, in later use we may
see AXI bus errors caused by accessing invalid addresses.

Signed-off-by: Yabin Cui <yabinc@google.com>
[ Tweak error message ]
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Link: https://lore.kernel.org/r/20230127231001.1920947-1-yabinc@google.com
drivers/hwtracing/coresight/coresight-tmc-core.c
drivers/hwtracing/coresight/coresight-tmc-etf.c
drivers/hwtracing/coresight/coresight-tmc-etr.c
drivers/hwtracing/coresight/coresight-tmc.h