]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
KVM: SEV: use mutex guard in sev_mem_enc_unregister_region()
authorCarlos López <clopez@suse.de>
Tue, 10 Mar 2026 23:48:26 +0000 (16:48 -0700)
committerSean Christopherson <seanjc@google.com>
Thu, 9 Apr 2026 19:00:22 +0000 (12:00 -0700)
commit84841f3941d7e837b23852e966c7bd4f4d6b62e6
tree80cc8a108be1f4bf7c025b2f4932d28f4e98c3ab
parent63e56d8425a71e20789f68c533f5615a9e7d43cc
KVM: SEV: use mutex guard in sev_mem_enc_unregister_region()

Simplify the error paths in sev_mem_enc_unregister_region() by using a
mutex guard, allowing early return instead of using gotos.

Signed-off-by: Carlos López <clopez@suse.de>
Link: https://patch.msgid.link/20260120201013.3931334-7-clopez@suse.de
Link: https://patch.msgid.link/20260310234829.2608037-19-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/svm/sev.c