diff options
author | Sheng Yang <sheng@linux.intel.com> | 2008-10-09 04:01:54 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2008-12-31 09:51:44 -0500 |
commit | 0bed3b568b68e5835ef5da888a372b9beabf7544 (patch) | |
tree | ec8d816662d845831055a411496c97523bdd5de1 /arch/x86/include | |
parent | 932d27a7913fc6b3c64c6e6082628b0a1561dec9 (diff) |
KVM: Improve MTRR structure
As well as reset mmu context when set MTRR.
Signed-off-by: Sheng Yang <sheng@linux.intel.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/include')
-rw-r--r-- | arch/x86/include/asm/kvm_host.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h index a40fa8478920..8082e87f628d 100644 --- a/arch/x86/include/asm/kvm_host.h +++ b/arch/x86/include/asm/kvm_host.h | |||
@@ -21,6 +21,7 @@ | |||
21 | 21 | ||
22 | #include <asm/pvclock-abi.h> | 22 | #include <asm/pvclock-abi.h> |
23 | #include <asm/desc.h> | 23 | #include <asm/desc.h> |
24 | #include <asm/mtrr.h> | ||
24 | 25 | ||
25 | #define KVM_MAX_VCPUS 16 | 26 | #define KVM_MAX_VCPUS 16 |
26 | #define KVM_MEMORY_SLOTS 32 | 27 | #define KVM_MEMORY_SLOTS 32 |
@@ -86,6 +87,7 @@ | |||
86 | #define KVM_MIN_FREE_MMU_PAGES 5 | 87 | #define KVM_MIN_FREE_MMU_PAGES 5 |
87 | #define KVM_REFILL_PAGES 25 | 88 | #define KVM_REFILL_PAGES 25 |
88 | #define KVM_MAX_CPUID_ENTRIES 40 | 89 | #define KVM_MAX_CPUID_ENTRIES 40 |
90 | #define KVM_NR_FIXED_MTRR_REGION 88 | ||
89 | #define KVM_NR_VAR_MTRR 8 | 91 | #define KVM_NR_VAR_MTRR 8 |
90 | 92 | ||
91 | extern spinlock_t kvm_lock; | 93 | extern spinlock_t kvm_lock; |
@@ -329,7 +331,8 @@ struct kvm_vcpu_arch { | |||
329 | bool nmi_injected; | 331 | bool nmi_injected; |
330 | bool nmi_window_open; | 332 | bool nmi_window_open; |
331 | 333 | ||
332 | u64 mtrr[0x100]; | 334 | struct mtrr_state_type mtrr_state; |
335 | u32 pat; | ||
333 | }; | 336 | }; |
334 | 337 | ||
335 | struct kvm_mem_alias { | 338 | struct kvm_mem_alias { |