diff options
author | Avi Kivity <avi@qumranet.com> | 2007-11-21 14:54:47 +0300 |
---|---|---|
committer | Avi Kivity <avi@qumranet.com> | 2008-01-30 18:53:10 +0300 |
commit | da928521b7a095e85f6ac92a6c106bca7e17625f (patch) | |
tree | 4c8fc2b3f056cd1bd7d335958bf384ebc62d8614 /drivers/kvm/mmu.c | |
parent | 5fb07ddb183eb4728f240e09c3305d271ce61d48 (diff) | |
download | linux-da928521b7a095e85f6ac92a6c106bca7e17625f.tar.xz |
KVM: MMU: Move pse36 handling to the guest walker
Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'drivers/kvm/mmu.c')
-rw-r--r-- | drivers/kvm/mmu.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/kvm/mmu.c b/drivers/kvm/mmu.c index 346aa65a08d5..a9fed594ac58 100644 --- a/drivers/kvm/mmu.c +++ b/drivers/kvm/mmu.c @@ -218,6 +218,13 @@ static int is_rmap_pte(u64 pte) && pte != shadow_notrap_nonpresent_pte; } +static gfn_t pse36_gfn_delta(u32 gpte) +{ + int shift = 32 - PT32_DIR_PSE36_SHIFT - PAGE_SHIFT; + + return (gpte & PT32_DIR_PSE36_MASK) << shift; +} + static void set_shadow_pte(u64 *sptep, u64 spte) { #ifdef CONFIG_X86_64 |