linux-kernel-test/arch/x86/kvm
Lai Jiangshan 2032a93d66 KVM: MMU: Don't allocate gfns page for direct mmu pages
When sp->role.direct is set, sp->gfns does not contain any essential
information, leaf sptes reachable from this sp are for a continuous
guest physical memory range (a linear range).
So sp->gfns[i] (if it was set) equals to sp->gfn + i. (PT_PAGE_TABLE_LEVEL)
Obviously, it is not essential information, we can calculate it when need.

It means we don't need sp->gfns when sp->role.direct=1,
Thus we can save one page usage for every kvm_mmu_page.

Note:
  Access to sp->gfns must be wrapped by kvm_mmu_page_get_gfn()
  or kvm_mmu_page_set_gfn().
  It is only exposed in FNAME(sync_page).

Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
2010-08-01 10:35:52 +03:00
..
emulate.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
i8254.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
i8254.h KVM: Convert i8254/i8259 locks to raw_spinlocks 2010-03-01 12:36:12 -03:00
i8259.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
irq.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
irq.h KVM: x86: Kick VCPU outside PIC lock again 2010-04-25 12:39:28 +03:00
Kconfig Merge branch 'kvm-updates/2.6.34' of git://git.kernel.org/pub/scm/virt/kvm/kvm 2010-03-05 13:12:34 -08:00
kvm_cache_regs.h KVM: kvm_pdptr_read() may sleep 2010-08-01 10:35:27 +03:00
kvm_timer.h KVM: arch/x86/kvm/kvm_timer.h checkpatch cleanup 2010-05-17 12:14:42 +03:00
lapic.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
lapic.h KVM: Add HYPER-V apic access MSRs 2010-03-01 12:36:00 -03:00
Makefile KVM: Move assigned device code to own file 2009-12-03 09:32:09 +02:00
mmu.c KVM: MMU: Don't allocate gfns page for direct mmu pages 2010-08-01 10:35:52 +03:00
mmu.h KVM: x86 emulator: fix memory access during x86 emulation 2010-03-01 12:36:11 -03:00
mmutrace.h KVM: MMU: convert mmu tracepoints 2010-05-19 11:36:26 +03:00
paging_tmpl.h KVM: MMU: Don't allocate gfns page for direct mmu pages 2010-08-01 10:35:52 +03:00
svm.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
timer.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
trace.h KVM: Trace emulated instructions 2010-05-17 12:17:35 +03:00
tss.h
vmx.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
x86.c KVM: Update Red Hat copyrights 2010-08-01 10:35:51 +03:00
x86.h KVM: use the correct RCU API for PROVE_RCU=y 2010-05-17 12:18:01 +03:00