Re: [PATCH v3 00/11] KVM: x86/mmu: refine memtype related mmu zap

From: Yan Zhao
Date: Fri Jul 14 2023 - 03:37:58 EST


On Wed, Jun 28, 2023 at 04:02:05PM -0700, Sean Christopherson wrote:
> On Fri, Jun 16, 2023, Yan Zhao wrote:
> > This series refines mmu zap caused by EPT memory type update when guest
> > MTRRs are honored.
>
> ...
>
> > Yan Zhao (11):
> > KVM: x86/mmu: helpers to return if KVM honors guest MTRRs
> > KVM: x86/mmu: Use KVM honors guest MTRRs helper in
> > kvm_tdp_page_fault()
> > KVM: x86/mmu: Use KVM honors guest MTRRs helper when CR0.CD toggles
> > KVM: x86/mmu: Use KVM honors guest MTRRs helper when update mtrr
> > KVM: x86/mmu: zap KVM TDP when noncoherent DMA assignment starts/stops
> > KVM: x86/mmu: move TDP zaps from guest MTRRs update to CR0.CD toggling
> > KVM: VMX: drop IPAT in memtype when CD=1 for
> > KVM_X86_QUIRK_CD_NW_CLEARED
> > KVM: x86: move vmx code to get EPT memtype when CR0.CD=1 to x86 common
> > code
> > KVM: x86/mmu: serialize vCPUs to zap gfn when guest MTRRs are honored
> > KVM: x86/mmu: fine-grained gfn zap when guest MTRRs are honored
> > KVM: x86/mmu: split a single gfn zap range when guest MTRRs are
> > honored
>
> I got through the easy patches, I'll circle back for the last few patches in a
> few weeks (probably 3+ weeks at this point).
Thanks for this heads-up.
I addressed almost all the comments for v3 currently, except about
where to get memtype for CR0.CD=1, and feel free to decline my new
proposal in v4 as explained in another mail :)
v4 is available here
https://lore.kernel.org/all/20230714064656.20147-1-yan.y.zhao@xxxxxxxxx/
Please review the new version directly.

Thanks!