]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: x86/mmu: Process only valid TDP MMU roots when aging a gfn range
authorSean Christopherson <seanjc@google.com>
Fri, 11 Oct 2024 02:10:45 +0000 (19:10 -0700)
committerSean Christopherson <seanjc@google.com>
Wed, 30 Oct 2024 21:46:47 +0000 (14:46 -0700)
commit526e609f05676c21aeed6c04115ae777c40081ec
treecd2fa7d1085254ee827567d5225871dd42f9958c
parent7971801b5618e37d7173f615300f640ab590ba6d
KVM: x86/mmu: Process only valid TDP MMU roots when aging a gfn range

Skip invalid TDP MMU roots when aging a gfn range.  There is zero reason
to process invalid roots, as they by definition hold stale information.
E.g. if a root is invalid because its from a previous memslot generation,
in the unlikely event the root has a SPTE for the gfn, then odds are good
that the gfn=>hva mapping is different, i.e. doesn't map to the hva that
is being aged by the primary MMU.

Link: https://lore.kernel.org/r/20241011021051.1557902-14-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/mmu/tdp_mmu.c