KVM: x86/mmu: Avoid memslot lookup in rmap_add
authorDavid Matlack <dmatlack@google.com>
Fri, 13 Aug 2021 20:35:03 +0000 (20:35 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 1 Oct 2021 07:44:56 +0000 (03:44 -0400)
commit8a9f566ae4a4156343afb5cbfa79401c07647b1d
tree60e069cbb56f1546987ed806a76fd302e2c95b41
parenta12f43818b3f8f2d85b961493ff134c19ffcd05b
KVM: x86/mmu: Avoid memslot lookup in rmap_add

Avoid the memslot lookup in rmap_add, by passing it down from the fault
handling code to mmu_set_spte and then to rmap_add.

No functional change intended.

Signed-off-by: David Matlack <dmatlack@google.com>
Message-Id: <20210813203504.2742757-6-dmatlack@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/mmu/mmu.c
arch/x86/kvm/mmu/paging_tmpl.h