]> git.ipfire.org Git - thirdparty/linux.git/commit
RISC-V: KVM: Implement kvm_arch_flush_remote_tlbs_range()
authorAnup Patel <apatel@ventanamicro.com>
Wed, 18 Jun 2025 11:35:26 +0000 (17:05 +0530)
committerAnup Patel <anup@brainfault.org>
Mon, 28 Jul 2025 16:57:18 +0000 (22:27 +0530)
commitca539ba4bc980610b68dba345b18208c0279b2b1
tree38051071424da3f3b6d0adebac41237c7bb6e31c
parenteaa98ba20be088eeb252061f216c299442ba5a69
RISC-V: KVM: Implement kvm_arch_flush_remote_tlbs_range()

The kvm_arch_flush_remote_tlbs_range() expected by KVM core can be
easily implemented for RISC-V using kvm_riscv_hfence_gvma_vmid_gpa()
hence provide it.

Also with kvm_arch_flush_remote_tlbs_range() available for RISC-V, the
mmu_wp_memory_region() can happily use kvm_flush_remote_tlbs_memslot()
instead of kvm_flush_remote_tlbs().

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Atish Patra <atishp@rivosinc.com>
Tested-by: Atish Patra <atishp@rivosinc.com>
Reviewed-by: Nutty Liu <liujingqi@lanxincomputing.com>
Link: https://lore.kernel.org/r/20250618113532.471448-7-apatel@ventanamicro.com
Signed-off-by: Anup Patel <anup@brainfault.org>
arch/riscv/include/asm/kvm_host.h
arch/riscv/kvm/mmu.c
arch/riscv/kvm/tlb.c