KVM: vmx: Inject #GP on invalid PAT CR
authorNadav Amit <namit@cs.technion.ac.il>
Thu, 18 Sep 2014 19:39:44 +0000 (22:39 +0300)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 24 Sep 2014 12:07:52 +0000 (14:07 +0200)
commit4566654bb9be9e8864df417bb72ceee5136b6a6a
tree2ee30a47fda49fb967dbad7ce7c0158f6e1023e4
parent040c8dc8a5afa7364bb8bb5b1b76c30007d6be14
KVM: vmx: Inject #GP on invalid PAT CR

Guest which sets the PAT CR to invalid value should get a #GP.  Currently, if
vmx supports loading PAT CR during entry, then the value is not checked.  This
patch makes the required check in that case.

Signed-off-by: Nadav Amit <namit@cs.technion.ac.il>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx.c
arch/x86/kvm/x86.c
arch/x86/kvm/x86.h