]> git.baikalelectronics.ru Git - kernel.git/commit
kvm: x86: Suppress CR3_PCID_INVD bit only when PCIDs are enabled
authorJunaid Shahid <junaids@google.com>
Fri, 4 May 2018 18:37:13 +0000 (11:37 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 11 May 2018 09:21:12 +0000 (11:21 +0200)
commit7f27a31dc3823c4d75f110e12786561419ddeb81
tree3d2dd64d5a9cd0d5ef154be7cce2ca944597a8c4
parent8e6722ea5bc41732bacb2f40acce8f2c05ebd077
kvm: x86: Suppress CR3_PCID_INVD bit only when PCIDs are enabled

If the PCIDE bit is not set in CR4, then the MSb of CR3 is a reserved
bit. If the guest tries to set it, that should cause a #GP fault. So
mask out the bit only when the PCIDE bit is set.

Signed-off-by: Junaid Shahid <junaids@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c