Commit 6abd817e authored by Quentin Perret's avatar Quentin Perret Committed by Will Deacon
Browse files

UPSTREAM: KVM: arm64: Release mmap_lock when using VM_SHARED with MTE



VM_SHARED mappings are currently forbidden in a memslot with MTE to
prevent two VMs racing to sanitise the same page. However, this check
is performed while holding current->mm's mmap_lock, but fails to release
it. Fix this by releasing the lock when needed.

Fixes: ea7fc1bb ("KVM: arm64: Introduce MTE VM feature")
Signed-off-by: default avatarQuentin Perret <qperret@google.com>
Signed-off-by: default avatarMarc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20211005122031.809857-1-qperret@google.com


(cherry picked from commit 6e6a8ef0)
Signed-off-by: default avatarWill Deacon <willdeacon@google.com>
Bug: 198418208
Change-Id: Ie1f956d5c33c2ecff832114216ae4cc509371ddb
parent ea1c63ba
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment