Skip to content

Commit f49731d

Browse files
bonzinigregkh
authored andcommitted
KVM: SEV: fix double locking due to incorrect backport
Fix an incorrect line in the 5.4.y and 4.19.y backports of commit 19a23da ("Fix unsynchronized access to sev members through svm_register_enc_region"), first applied to 5.4.98 and 4.19.176. Fixes: 1e80fdc ("KVM: SVM: Pin guest memory when SEV is active") Reported-by: Dov Murik <dovmurik@linux.vnet.ibm.com> Cc: stable@vger.kernel.org # 5.4.x Cc: stable@vger.kernel.org # 4.19.x Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent 850e6a9 commit f49731d

1 file changed

Lines changed: 0 additions & 1 deletion

File tree

arch/x86/kvm/svm.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7104,7 +7104,6 @@ static int svm_register_enc_region(struct kvm *kvm,
71047104
region->uaddr = range->addr;
71057105
region->size = range->size;
71067106

7107-
mutex_lock(&kvm->lock);
71087107
list_add_tail(&region->list, &sev->regions_list);
71097108
mutex_unlock(&kvm->lock);
71107109

0 commit comments

Comments
 (0)