aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorCatalin Marinas <[email protected]>2022-05-17 10:35:32 +0100
committerWill Deacon <[email protected]>2022-05-17 14:29:51 +0100
commit1d0cb4c8864addc362bae98e8ffa5500c87e1227 (patch)
treea86bef28c0094d659065a86755b5b14fe433fa24 /scripts
parenteb3d8ea3e1f03f4b0b72d8f5ed9eb7c3165862e8 (diff)
arm64: mte: Ensure the cleared tags are visible before setting the PTE
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. Signed-off-by: Catalin Marinas <[email protected]> Fixes: 34bfeea4a9e9 ("arm64: mte: Clear the tags when a page is mapped in user-space with PROT_MTE") Cc: <[email protected]> # 5.10.x Reported-by: Vladimir Murzin <[email protected]> Cc: Will Deacon <[email protected]> Reviewed-by: Steven Price <[email protected]> Tested-by: Vladimir Murzin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions