Skip to content

Commit e8be2a5

Browse files
sean-jcbonzini
authored andcommitted
KVM: x86/mmu: Drop a redundant remote TLB flush in kvm_zap_gfn_range()
Remove an unnecessary remote TLB flush in kvm_zap_gfn_range() now that said function holds mmu_lock for write for its entire duration. The flush was added by the now-reverted commit to allow TDP MMU to flush while holding mmu_lock for read, as the transition from write=>read required dropping the lock and thus a pending flush needed to be serviced. Fixes: 5a324c2 ("Revert "KVM: x86/mmu: Allow zap gfn range to operate under the mmu read lock"") Cc: Maxim Levitsky <[email protected]> Cc: Maciej S. Szmigiero <[email protected]> Cc: Ben Gardon <[email protected]> Signed-off-by: Sean Christopherson <[email protected]> Message-Id: <[email protected]> Signed-off-by: Paolo Bonzini <[email protected]>
1 parent bc3b3c1 commit e8be2a5

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

arch/x86/kvm/mmu/mmu.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5743,9 +5743,6 @@ void kvm_zap_gfn_range(struct kvm *kvm, gfn_t gfn_start, gfn_t gfn_end)
57435743
end - 1, true, flush);
57445744
}
57455745
}
5746-
if (flush)
5747-
kvm_flush_remote_tlbs_with_address(kvm, gfn_start,
5748-
gfn_end - gfn_start);
57495746
}
57505747

57515748
if (is_tdp_mmu_enabled(kvm)) {

0 commit comments

Comments
 (0)