Re: [BUG] CoreSight: WARN_ON in coresight_disclaim_device_unlocked due to register reset on CPU power-cycle

From: James Clark
Date: Mon Jun 23 2025 - 08:14:06 EST




On 23/06/2025 9:59 am, Keita Morisaki wrote:
We have the ETM driver performing the save/restore of ETM context during
a CPUidle. This is only done when the ETM/ETE is described to be loosing
context over PM operation. If this is not done (via DT), the driver
doesn't do anything. This could be problematic. Could you try adding:

"arm,coresight-loses-context-with-cpu"


property to the ETE nodes and see if it makes a difference ?

I tried this in our environment, and this worked well. The "arm,coresight-loses-context-with-cpu" property was what we needed.
Thank you so much again for the swift response with the useful information!

Best,
Keita


Hi Keita,

Thanks for the report. We discussed internally and decided that it would be better for the driver to always save the context by default, because this mistake is easy to make. Saving when it doesn't need to be saved doesn't do any harm, but not saving when it should be causes quite bad bugs.

So "arm,coresight-loses-context-with-cpu" will be ignored in the future and we'll add a new flag like "arm,coresight-save-context" if anyone wants the optimization of not saving.

Thanks
James