Re: [GIT PULL] KVM: x86: MMU changes for 6.6
From: Sean Christopherson
Date: Thu Aug 31 2023 - 13:27:44 EST
+Like
On Tue, Aug 29, 2023, Sean Christopherson wrote:
> Please pull MMU changes for 6.6, with a healthy dose of KVMGT cleanups mixed in.
> The other highlight is finally purging the old MMU_DEBUG code and replacing it
> with CONFIG_KVM_PROVE_MMU.
>
> All KVMGT patches have been reviewed/acked and tested by KVMGT folks. A *huge*
> thanks to them for all the reviews and testing, and to Yan in particular.
FYI, Like found a brown paper bag bug[*] that causes selftests that move memory
regions to fail when compiled with CONFIG_KVM_EXTERNAL_WRITE_TRACKING=y. I'm
redoing testing today with that forced on, but barring more falling, the fix is:
diff --git a/arch/x86/kvm/mmu/page_track.c b/arch/x86/kvm/mmu/page_track.c
index b5af8249eb09..cfd0b8092d06 100644
--- a/arch/x86/kvm/mmu/page_track.c
+++ b/arch/x86/kvm/mmu/page_track.c
@@ -306,5 +306,5 @@ void kvm_page_track_flush_slot(struct kvm *kvm, struct kvm_memory_slot *slot)
bool kvm_page_track_has_external_user(struct kvm *kvm)
{
- return hlist_empty(&kvm->arch.track_notifier_head.track_notifier_list);
+ return !hlist_empty(&kvm->arch.track_notifier_head.track_notifier_list);
}
[*] https://lkml.kernel.org/r/7a6488f2-fef4-6709-6a95-168b0c034ff4%40gmail.com