]> git.baikalelectronics.ru Git - kernel.git/commit
kvm: x86/mmu: Allocate and free TDP MMU roots
authorBen Gardon <bgardon@google.com>
Wed, 14 Oct 2020 18:26:44 +0000 (20:26 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 21 Oct 2020 22:17:00 +0000 (18:17 -0400)
commited5c11e27840d58d2abad7644ad36246dae6e595
tree27104f708676fc7ad3d2ff5fecfa9dda4b70ded0
parent1e92e4b666a7a83876be159e309111566f43f012
kvm: x86/mmu: Allocate and free TDP MMU roots

The TDP MMU must be able to allocate paging structure root pages and track
the usage of those pages. Implement a similar, but separate system for root
page allocation to that of the x86 shadow paging implementation. When
future patches add synchronization model changes to allow for parallel
page faults, these pages will need to be handled differently from the
x86 shadow paging based MMU's root pages.

Tested by running kvm-unit-tests and KVM selftests on an Intel Haswell
machine. This series introduced no new failures.

This series can be viewed in Gerrit at:
https://linux-review.googlesource.com/c/virt/kvm/kvm/+/2538

Signed-off-by: Ben Gardon <bgardon@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/mmu/mmu.c
arch/x86/kvm/mmu/mmu_internal.h
arch/x86/kvm/mmu/tdp_mmu.c
arch/x86/kvm/mmu/tdp_mmu.h