android_kernel_xiaomi_sm8350/drivers/kvm
Avi Kivity cea0f0e7ea [PATCH] KVM: MMU: Shadow page table caching
Define a hashtable for caching shadow page tables. Look up the cache on
context switch (cr3 change) or during page faults.

The key to the cache is a combination of
- the guest page table frame number
- the number of paging levels in the guest
   * we can cache real mode, 32-bit mode, pae, and long mode page
     tables simultaneously.  this is useful for smp bootup.
- the guest page table table
   * some kernels use a page as both a page table and a page directory.  this
     allows multiple shadow pages to exist for that page, one per level
- the "quadrant"
   * 32-bit mode page tables span 4MB, whereas a shadow page table spans
     2MB.  similarly, a 32-bit page directory spans 4GB, while a shadow
     page directory spans 1GB.  the quadrant allows caching up to 4 shadow page
     tables for one guest page in one level.
- a "metaphysical" bit
   * for real mode, and for pse pages, there is no guest page table, so set
     the bit to avoid write protecting the page.

Signed-off-by: Avi Kivity <avi@qumranet.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2007-01-05 23:55:24 -08:00
..
Kconfig [PATCH] KVM: Put KVM in a new Virtualization menu 2006-12-13 09:05:46 -08:00
kvm_main.c [PATCH] KVM: MMU: Use the guest pdptrs instead of mapping cr3 in pae mode 2007-01-05 23:55:24 -08:00
kvm_svm.h [PATCH] KVM: Replace __x86_64__ with CONFIG_X86_64 2006-12-13 09:05:46 -08:00
kvm_vmx.h [PATCH] KVM: Replace __x86_64__ with CONFIG_X86_64 2006-12-13 09:05:46 -08:00
kvm.h [PATCH] KVM: MMU: Shadow page table caching 2007-01-05 23:55:24 -08:00
Makefile
mmu.c [PATCH] KVM: MMU: Shadow page table caching 2007-01-05 23:55:24 -08:00
paging_tmpl.h [PATCH] KVM: MMU: Shadow page table caching 2007-01-05 23:55:24 -08:00
segment_descriptor.h
svm.c [PATCH] KVM: Prevent stale bits in cr0 and cr4 2007-01-05 23:55:23 -08:00
svm.h
vmx.c [PATCH] KVM: Prevent stale bits in cr0 and cr4 2007-01-05 23:55:23 -08:00
vmx.h [PATCH] KVM: Rename some msrs 2006-12-30 10:56:44 -08:00
x86_emulate.c [PATCH] KVM: Replace __x86_64__ with CONFIG_X86_64 2006-12-13 09:05:46 -08:00
x86_emulate.h [PATCH] KVM: Replace __x86_64__ with CONFIG_X86_64 2006-12-13 09:05:46 -08:00