]> git.ipfire.org Git - thirdparty/linux.git/commit
KVM: SEV: Explicitly validate the dst buffer for debug operations
authorSean Christopherson <seanjc@google.com>
Fri, 1 May 2026 20:35:34 +0000 (13:35 -0700)
committerSean Christopherson <seanjc@google.com>
Wed, 13 May 2026 22:03:17 +0000 (15:03 -0700)
commitcb32e895546bf45ebdd0e76ae7a7d783eed2c304
tree10c82d046a9756bc7cc50a07865a97ceb7a8d05e
parent6edd35e77a42ee3e72405619049a45bf368f9ab2
KVM: SEV: Explicitly validate the dst buffer for debug operations

When encrypting/decrypting guest memory, explicitly check that the
destination is non-NULL and doesn't wrap instead of subtly relying on
sev_pin_memory() to perform the check.  This will allow adding and using
a more focused single-page pinning helper.

Link: https://patch.msgid.link/20260501203537.2120074-4-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/svm/sev.c