Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

KVM/MMU: Flush tlb directly in kvm_set_pte_rmapp()

This patch is to flush tlb directly in kvm_set_pte_rmapp()
function when Hyper-V remote TLB flush is available, returning 0
so that kvm_mmu_notifier_change_pte() does not flush again.

Signed-off-by: Lan Tianyu <Tianyu.Lan@microsoft.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>

authored by

Lan Tianyu and committed by
Paolo Bonzini
3cc5ea94 0cf853c5

+5
+5
arch/x86/kvm/mmu.c
··· 1776 1776 } 1777 1777 } 1778 1778 1779 + if (need_flush && kvm_available_flush_tlb_with_range()) { 1780 + kvm_flush_remote_tlbs_with_address(kvm, gfn, 1); 1781 + return 0; 1782 + } 1783 + 1779 1784 return need_flush; 1780 1785 } 1781 1786