[PATCH] arm64: mte: Make mte_check_tfsr_*() conditional on KASAN instead of MTE

Catalin Marinas catalin.marinas at arm.com
Wed Jun 12 09:09:11 PDT 2024


On Tue, 28 May 2024 15:51:30 -0700, Peter Collingbourne wrote:
> The check in mte_check_tfsr_el1() is only necessary if HW tag
> based KASAN is enabled. However, we were also executing the check
> if MTE is enabled and KASAN is enabled at build time but disabled
> at runtime. This turned out to cause a measurable increase in
> power consumption on a specific microarchitecture after enabling
> MTE. Moreover, on the same system, an increase in invalid syscall
> latency (as measured by [1]) of around 20-30% (depending on the
> cluster) was observed after enabling MTE; this almost entirely goes
> away after removing this check. Therefore, make the check conditional
> on whether KASAN is enabled rather than on whether MTE is enabled.
> 
> [...]

Applied to arm64 (for-next/mte), thanks!

[1/1] arm64: mte: Make mte_check_tfsr_*() conditional on KASAN instead of MTE
      https://git.kernel.org/arm64/c/26ca4423604f

-- 
Catalin




More information about the linux-arm-kernel mailing list