summaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/x86.h
diff options
context:
space:
mode:
authorNadav Amit <namit@cs.technion.ac.il>2014-09-18 22:39:44 +0300
committerPaolo Bonzini <pbonzini@redhat.com>2014-09-24 14:07:52 +0200
commit4566654bb9be9e8864df417bb72ceee5136b6a6a (patch)
tree2ee30a47fda49fb967dbad7ce7c0158f6e1023e4 /arch/x86/kvm/x86.h
parent040c8dc8a5afa7364bb8bb5b1b76c30007d6be14 (diff)
downloadop-kernel-dev-4566654bb9be9e8864df417bb72ceee5136b6a6a.zip
op-kernel-dev-4566654bb9be9e8864df417bb72ceee5136b6a6a.tar.gz
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>
Diffstat (limited to 'arch/x86/kvm/x86.h')
-rw-r--r--arch/x86/kvm/x86.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kvm/x86.h b/arch/x86/kvm/x86.h
index 985fb2c..7cb9c45 100644
--- a/arch/x86/kvm/x86.h
+++ b/arch/x86/kvm/x86.h
@@ -159,6 +159,8 @@ int kvm_write_guest_virt_system(struct x86_emulate_ctxt *ctxt,
gva_t addr, void *val, unsigned int bytes,
struct x86_exception *exception);
+bool kvm_mtrr_valid(struct kvm_vcpu *vcpu, u32 msr, u64 data);
+
#define KVM_SUPPORTED_XCR0 (XSTATE_FP | XSTATE_SSE | XSTATE_YMM \
| XSTATE_BNDREGS | XSTATE_BNDCSR)
extern u64 host_xcr0;
OpenPOWER on IntegriCloud