]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: MMU: pass struct kvm_page_fault to mmu_set_spte
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 17 Aug 2021 11:49:47 +0000 (07:49 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 1 Oct 2021 07:44:56 +0000 (03:44 -0400)
commit796f665a24d16aa03d2aff73d4d281a30caacb39
treee6e40c1998f5bf747e44e053deebdc526f0e86cf
parent1f4e4ff23e968de9e6ee42ce62bb8116a3ee5cee
KVM: MMU: pass struct kvm_page_fault to mmu_set_spte

mmu_set_spte is called for either PTE prefetching or page faults.  The
three boolean arguments write_fault, speculative and host_writable are
always respectively false/true/true for prefetching and coming from
a struct kvm_page_fault for page faults.

Let mmu_set_spte distinguish these two situation by accepting a
possibly NULL struct kvm_page_fault argument.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/mmu/mmu.c
arch/x86/kvm/mmu/paging_tmpl.h