diff options
author | Dong, Eddie <eddie.dong@intel.com> | 2009-03-31 15:03:45 (GMT) |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2009-06-10 08:48:36 (GMT) |
commit | 20c466b56168ddccf034c136510d73e4a0e18605 (patch) | |
tree | 92da7e4f5daab7ed5573b64819e8b1389d1c1287 /arch/x86/kvm/mmu.c | |
parent | 93ba03c2e2aba23b042cc15eef83b7a66d3ac17a (diff) | |
download | linux-fsl-qoriq-20c466b56168ddccf034c136510d73e4a0e18605.tar.xz |
KVM: Use rsvd_bits_mask in load_pdptrs()
Also remove bit 5-6 from rsvd_bits_mask per latest SDM.
Signed-off-by: Eddie Dong <Eddie.Dong@intel.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/kvm/mmu.c')
-rw-r--r-- | arch/x86/kvm/mmu.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index b2c8e28..da3ad3c 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c @@ -225,11 +225,6 @@ static int is_nx(struct kvm_vcpu *vcpu) return vcpu->arch.shadow_efer & EFER_NX; } -static int is_present_pte(unsigned long pte) -{ - return pte & PT_PRESENT_MASK; -} - static int is_shadow_present_pte(u64 pte) { return pte != shadow_trap_nonpresent_pte @@ -2195,6 +2190,9 @@ static void reset_rsvds_bits_mask(struct kvm_vcpu *vcpu, int level) context->rsvd_bits_mask[1][0] = ~0ull; break; case PT32E_ROOT_LEVEL: + context->rsvd_bits_mask[0][2] = + rsvd_bits(maxphyaddr, 63) | + rsvd_bits(7, 8) | rsvd_bits(1, 2); /* PDPTE */ context->rsvd_bits_mask[0][1] = exb_bit_rsvd | rsvd_bits(maxphyaddr, 62); /* PDE */ context->rsvd_bits_mask[0][0] = exb_bit_rsvd | |