linux/arch/x86/kvm/mmu
David Stevens deae4a10f1 KVM: x86: only allocate gfn_track when necessary
Avoid allocating the gfn_track arrays if nothing needs them. If there
are no external to KVM users of the API (i.e. no GVT-g), then page
tracking is only needed for shadow page tables. This means that when tdp
is enabled and there are no external users, then the gfn_track arrays
can be lazily allocated when the shadow MMU is actually used. This avoid
allocations equal to .05% of guest memory when nested virtualization is
not used, if the kernel is compiled without GVT-g.

Signed-off-by: David Stevens <stevensd@chromium.org>
Message-Id: <20210922045859.2011227-3-stevensd@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-10-01 03:44:58 -04:00
..
mmu_audit.c KVM: x86/mmu: Rename __gfn_to_rmap to gfn_to_rmap 2021-08-06 07:52:58 -04:00
mmu_internal.h KVM: x86/mmu: Avoid memslot lookup in make_spte and mmu_try_to_unsync_pages 2021-10-01 03:44:56 -04:00
mmu.c KVM: x86: only allocate gfn_track when necessary 2021-10-01 03:44:58 -04:00
mmutrace.h KVM: MMU: change tracepoints arguments to kvm_page_fault 2021-10-01 03:44:52 -04:00
page_track.c KVM: x86: only allocate gfn_track when necessary 2021-10-01 03:44:58 -04:00
paging_tmpl.h KVM: x86/mmu: Avoid memslot lookup in make_spte and mmu_try_to_unsync_pages 2021-10-01 03:44:56 -04:00
paging.h KVM: x86/mmu: Do not apply HPA (memory encryption) mask to GPAs 2021-07-14 12:17:56 -04:00
spte.c KVM: x86/mmu: Avoid memslot lookup in make_spte and mmu_try_to_unsync_pages 2021-10-01 03:44:56 -04:00
spte.h KVM: x86/mmu: Avoid memslot lookup in make_spte and mmu_try_to_unsync_pages 2021-10-01 03:44:56 -04:00
tdp_iter.c KVM: x86/mmu: Store the address space ID in the TDP iterator 2021-03-16 14:16:34 -04:00
tdp_iter.h KVM: x86/mmu: Store the address space ID in the TDP iterator 2021-03-16 14:16:34 -04:00
tdp_mmu.c KVM: x86/mmu: Avoid memslot lookup in make_spte and mmu_try_to_unsync_pages 2021-10-01 03:44:56 -04:00
tdp_mmu.h KVM: MMU: change kvm_tdp_mmu_map() arguments to kvm_page_fault 2021-10-01 03:44:50 -04:00