summaryrefslogtreecommitdiffstats
path: root/arch/riscv/kvm
diff options
context:
space:
mode:
authorAndrew Jones <ajones@ventanamicro.com>2023-01-28 18:28:55 +0100
committerPalmer Dabbelt <palmer@rivosinc.com>2023-02-01 08:29:44 +0100
commite8ad17d2b5f38e595d597a3e2419d6d7cc727b17 (patch)
tree162250540be27620ce9e9f2db7d3e24746dc3579 /arch/riscv/kvm
parentriscv: cpu_relax: switch to riscv_has_extension_likely() (diff)
downloadlinux-e8ad17d2b5f38e595d597a3e2419d6d7cc727b17.tar.xz
linux-e8ad17d2b5f38e595d597a3e2419d6d7cc727b17.zip
riscv: KVM: Switch has_svinval() to riscv_has_extension_unlikely()
Switch has_svinval() from static branch to the new helper riscv_has_extension_unlikely(). Signed-off-by: Andrew Jones <ajones@ventanamicro.com> Reviewed-by: Guo Ren <guoren@kernel.org> Acked-by: Anup Patel <anup@brainfault.org> Link: https://lore.kernel.org/r/20230128172856.3814-13-jszhang@kernel.org Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Diffstat (limited to 'arch/riscv/kvm')
-rw-r--r--arch/riscv/kvm/tlb.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/riscv/kvm/tlb.c b/arch/riscv/kvm/tlb.c
index 309d79b3e5cd..aa3da18ad873 100644
--- a/arch/riscv/kvm/tlb.c
+++ b/arch/riscv/kvm/tlb.c
@@ -15,8 +15,7 @@
#include <asm/hwcap.h>
#include <asm/insn-def.h>
-#define has_svinval() \
- static_branch_unlikely(&riscv_isa_ext_keys[RISCV_ISA_EXT_KEY_SVINVAL])
+#define has_svinval() riscv_has_extension_unlikely(RISCV_ISA_EXT_SVINVAL)
void kvm_riscv_local_hfence_gvma_vmid_gpa(unsigned long vmid,
gpa_t gpa, gpa_t gpsz,