Re: [PATCH] KVM: x86/mmu: Treat TDP MMU faults as spurious if access is already allowed
From: Sean Christopherson
Date: Wed Dec 18 2024 - 21:41:33 EST
On Wed, 18 Dec 2024 13:36:11 -0800, Sean Christopherson wrote:
> Treat slow-path TDP MMU faults as spurious if the access is allowed given
> the existing SPTE to fix a benign warning (other than the WARN itself)
> due to replacing a writable SPTE with a read-only SPTE, and to avoid the
> unnecessary LOCK CMPXCHG and subsequent TLB flush.
>
> If a read fault races with a write fault, fast GUP fails for any reason
> when trying to "promote" the read fault to a writable mapping, and KVM
> resolves the write fault first, then KVM will end up trying to install a
> read-only SPTE (for a !map_writable fault) overtop a writable SPTE.
>
> [...]
Applied very quickly to kvm-x86 fixes, so that it can get at least one day in
-next before I send it to Paolo.
[1/1] KVM: x86/mmu: Treat TDP MMU faults as spurious if access is already allowed
https://github.com/kvm-x86/linux/commit/55f60a6498e7
--
https://github.com/kvm-x86/linux/tree/next