Thread (14 messages) 14 messages, 3 authors, 2023-01-25

Re: [RFC PATCH 3/6] KVM: Define kvm_flush_remote_tlbs_range

From: David Matlack <dmatlack@google.com>
Date: 2023-01-09 23:47:41
Also in: kvm, kvmarm, lkml

On Mon, Jan 9, 2023 at 3:41 PM David Matlack [off-list ref] wrote:
On Mon, Jan 09, 2023 at 09:53:44PM +0000, Raghavendra Rao Ananta wrote:
quoted
+{
+     kvm_flush_remote_tlbs(kvm);
+}
FYI I also proposed a common kvm_flush_remote_tlbs() in my Common MMU
series [1].

Could I interest you in grabbing patches 29-33 from that series, which
has the same end result (common kvm_flush_remote_tlbs_range()) but also
hooks up the KVM/x86 range-based flushing, and folding them into this
series?

[1] https://lore.kernel.org/kvm/20221208193857.4090582-33-dmatlack@google.com/ (local)
(Also they make kvm_arch_flush_remote_tlbs_memslot() common so you
don't need the ARM-specific implementation in patch 4.)
quoted
 #endif

 static void kvm_flush_shadow_all(struct kvm *kvm)
@@ -637,7 +642,7 @@ static __always_inline int __kvm_handle_hva_range(struct kvm *kvm,
      }

      if (range->flush_on_ret && ret)
-             kvm_flush_remote_tlbs(kvm);
+             kvm_flush_remote_tlbs_range(kvm, range->start, range->end - 1);

      if (locked) {
              KVM_MMU_UNLOCK(kvm);
--
2.39.0.314.g84b9a713c41-goog
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help