OSDN Git Service

KVM: VMX: Invert handling of CR0.WP for EPT without unrestricted guest
authorSean Christopherson <seanjc@google.com>
Tue, 13 Jul 2021 16:32:59 +0000 (09:32 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 2 Aug 2021 15:01:53 +0000 (11:01 -0400)
commitee5a5584cba316bc90bc2fad0c6d10b71f1791cb
tree40e12b9b4d462a9557c849cd690a89172e4978bf
parent9e90e215d9c9f013cc354c4fe1a1313531a97a05
KVM: VMX: Invert handling of CR0.WP for EPT without unrestricted guest

Opt-in to forcing CR0.WP=1 for shadow paging, and stop lying about WP
being "always on" for unrestricted guest.  In addition to making KVM a
wee bit more honest, this paves the way for additional cleanup.

No functional change intended.

Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20210713163324.627647-22-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx/vmx.c