Skip to content

KVM: x86: Ensure userspace can't run L2 with stale PFNs

Sean Christopherson kvm lkml 1 version Applied

Status from this message: Applied to kvm-x86 fixes, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v2 Latest2 patches 1 replyApplied

Changes in v2 from the cover letter

- Re-pend KVM_REQ_GET_NESTED_STATE_PAGES in the common vcpu_enter_guest() path.
- Fix the kvm_run bug(s).

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/2KVM: x86: Re-pend GET_NESTED_STATE_PAGES if getting said pages failsarch/x86/kvm/x86.c+1 -00 replies
2/2KVM: x86: Fill kvm_run exit fields in common get_nested_state_pages() error pathsarch/x86/kvm/svm/nested.c arch/x86/kvm/vmx/nested.c arch/x86/kvm/x86.c+9 -160 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/2] KVM: x86: Ensure userspace can't run L2 with stale PFNs

Fix a class of bugs where KVM (a) lets userspace run L2 with potentially stale PFNs and (b) fails to set kvm_run appropriately and so could unintentionally cause a well-behaved VMM to run afoul of (a).

v2:
- Re-pend KVM_REQ_GET_NESTED_STATE_PAGES in the common vcpu_enter_guest() path.
- Fix the kvm_run bug(s).

v1: https://lore.kernel.org/all/[email protected]

Sean Christopherson (2):
KVM: x86: Re-pend GET_NESTED_STATE_PAGES if getting said pages fails
KVM: x86: Fill kvm_run exit fields in common get_nested_state_pages()
error paths

 arch/x86/kvm/svm/nested.c |  7 +------
 arch/x86/kvm/vmx/nested.c | 15 +++++----------
 arch/x86/kvm/x86.c        |  4 ++++
 3 files changed, 10 insertions(+), 16 deletions(-)

base-commit: 70c944caf570fda2d79baa71435589a8db39f048

Signature · 1 line
2.55.0.1082.g2b9226bbc0-goog