Re: [PATCH 3/4] KVM: x86/mmu: Make sure pfn is not changed for spurious fault

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Feb 07, 2025 at 07:07:06AM -0800, Sean Christopherson wrote:
> On Fri, Feb 07, 2025, Yan Zhao wrote:
> > Make sure pfn is not changed for a spurious fault by warning in the TDP
> > MMU. For shadow path, only treat a prefetch fault as spurious when pfn is
> > not changed, since the rmap removal and add are required when pfn is
> > changed.
> 
> I like sanity checks, but I don't like special casing "prefetch" faults like this.
> KVM should _never_ change the PFN of a shadow-present SPTE.  The TDP MMU already
> BUG()s on this, and mmu_spte_update() WARNs on the transition.
However, both TDP MMU and mmu_set_spte() return RET_PF_SPURIOUS directly before
the BUG() in TDP MMU or mmu_spte_update() could be hit.






[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux