linux/arch/x86/kvm/mmu
Tao Su db574f2f96 KVM: x86/mmu: Don't save mmu_invalidate_seq after checking private attr
Drop the second snapshot of mmu_invalidate_seq in kvm_faultin_pfn().
Before checking the mismatch of private vs. shared, mmu_invalidate_seq is
saved to fault->mmu_seq, which can be used to detect an invalidation
related to the gfn occurred, i.e. KVM will not install a mapping in page
table if fault->mmu_seq != mmu_invalidate_seq.

Currently there is a second snapshot of mmu_invalidate_seq, which may not
be same as the first snapshot in kvm_faultin_pfn(), i.e. the gfn attribute
may be changed between the two snapshots, but the gfn may be mapped in
page table without hindrance. Therefore, drop the second snapshot as it
has no obvious benefits.

Fixes: f6adeae81f ("KVM: x86/mmu: Handle no-slot faults at the beginning of kvm_faultin_pfn()")
Signed-off-by: Tao Su <tao1.su@linux.intel.com>
Message-ID: <20240528102234.2162763-1-tao1.su@linux.intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2024-06-05 06:45:06 -04:00
..
mmu_internal.h KVM: x86/mmu: Initialize kvm_page_fault's pfn and hva to error values 2024-05-07 11:59:23 -04:00
mmu.c KVM: x86/mmu: Don't save mmu_invalidate_seq after checking private attr 2024-06-05 06:45:06 -04:00
mmutrace.h KVM: x86/mmu: Pass full 64-bit error code when handling page faults 2024-05-07 11:59:18 -04:00
page_track.c KVM: Use vfree for memory allocated by vcalloc()/__vcalloc() 2024-04-09 12:18:38 -07:00
page_track.h KVM: x86/mmu: Drop @slot param from exported/external page-track APIs 2023-08-31 14:08:18 -04:00
paging_tmpl.h KVM VMX changes for 6.10: 2024-05-12 03:17:17 -04:00
spte.c KVM: x86/mmu: Track shadow MMIO value on a per-VM basis 2024-04-19 12:15:20 -04:00
spte.h KVM: x86/mmu: Add sanity checks that KVM doesn't create EPT #VE SPTEs 2024-05-23 12:27:26 -04:00
tdp_iter.c arch/x86: Fix typos 2024-01-03 11:46:22 +01:00
tdp_iter.h KVM: x86/mmu: Add sanity checks that KVM doesn't create EPT #VE SPTEs 2024-05-23 12:27:26 -04:00
tdp_mmu.c KVM: x86/mmu: Use SHADOW_NONPRESENT_VALUE for atomic zap in TDP MMU 2024-05-23 12:24:39 -04:00
tdp_mmu.h KVM: delete .change_pte MMU notifier callback 2024-04-11 13:18:27 -04:00