[PATCH v2] arm64: mte: Ensure the cleared tags are visible before setting the PTE

Will Deacon will at kernel.org
Tue May 17 07:04:42 PDT 2022


On Tue, 17 May 2022 10:35:32 +0100, Catalin Marinas wrote:
> As an optimisation, only pages mapped with PROT_MTE in user space have
> the MTE tags zeroed. This is done lazily at the set_pte_at() time via
> mte_sync_tags(). However, this function is missing a barrier and another
> CPU may see the PTE updated before the zeroed tags are visible. Add an
> smp_wmb() barrier if the mapping is Normal Tagged.
> 
> 
> [...]

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

[1/1] arm64: mte: Ensure the cleared tags are visible before setting the PTE
      https://git.kernel.org/arm64/c/1d0cb4c8864a

Cheers,
-- 
Will

https://fixes.arm64.dev
https://next.arm64.dev
https://will.arm64.dev



More information about the linux-arm-kernel mailing list