[PATCH] KVM: arm64: Disable TRBE Trace Buffer Unit when running in guest context

Leo Yan leo.yan at arm.com
Thu Feb 19 11:06:38 PST 2026


On Thu, Feb 19, 2026 at 06:58:03PM +0000, Leo Yan wrote:

[...]

> The flow for guest->host might be easy one, anyway, I try to summary for
> review:
> 
>   Restore TRFCR_EL1;
> 
>   // Ensure restored sysreg is visible
>   isb();
> 
>   // Enable trace buffer
>   TRBLIMITR_EL1.E = 0b1
> 
>   // Enable trace unit
>   TRCPRGCTLR.EN = 0b1
> 
>   if (2038923)
>      isb();

To strictly follow the SDEN, this ISB should be moved to immediately
after enabling the TRBLIMITR_EL1.E bit and before enabling the
TRCPRGCTLR.EN bit.

Sorry for spamming.



More information about the linux-arm-kernel mailing list