This series adds a shutdown callback to TMC ETR/ETF to ensure that it is properly shutdown in reboot/shutdown path. This is required for ETR/ETF which has SMMU address translation enabled like on SC7180 SoC and few others. If the hardware is still accessing memory after SMMU translation is disabled as part of SMMU shutdown callback in system reboot or shutdown path, then IOVAs(I/O virtual address) which it was using will go on the bus as the physical addresses which might result in unknown crashes (NoC/interconnect errors). So we make sure from this shutdown callback that the ETR/ETF is shutdown before SMMU translation is disabled and device_link in SMMU driver will take care of ordering of shutdown callbacks such that SMMU shutdown callback is not called before any of its consumer shutdown callbacks.
Sai Prakash Ranjan (2): coresight: tmc: Add enable flag to indicate the status of ETR/ETF coresight: tmc: Add shutdown callback for TMC ETR/ETF
.../hwtracing/coresight/coresight-tmc-etf.c | 4 +-- .../hwtracing/coresight/coresight-tmc-etr.c | 2 +- drivers/hwtracing/coresight/coresight-tmc.c | 31 +++++++++++++++++++ drivers/hwtracing/coresight/coresight-tmc.h | 5 +++ 4 files changed, 39 insertions(+), 3 deletions(-)
base-commit: 059e38815950dbec65beafe03757bce9436e89a4