Re: [PATCH 20/22] kvm: mmu: NX largepage recovery for TDP MMU

From: Ben Gardon
Date: Wed Sep 30 2020 - 18:23:52 EST


On Fri, Sep 25, 2020 at 6:15 PM Paolo Bonzini <pbonzini@xxxxxxxxxx> wrote:
>
> On 25/09/20 23:23, Ben Gardon wrote:
> > +
> > + if (!kvm->arch.tdp_mmu_enabled)
> > + return err;
> > +
> > + err = kvm_vm_create_worker_thread(kvm, kvm_nx_lpage_recovery_worker, 1,
> > + "kvm-nx-lpage-tdp-mmu-recovery",
> > + &kvm->arch.nx_lpage_tdp_mmu_recovery_thread);
>
> Any reason to have two threads?
>
> Paolo

At some point it felt cleaner. In this patch set NX reclaim is pretty
similar between the "shadow MMU" and TDP MMU so they don't really need
to be separate threads.

>