Skip to content

Commit

Permalink
riscv: KVM: Switch has_svinval() to riscv_has_extension_unlikely()
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Andrew Jones authored and Palmer Dabbelt committed Feb 1, 2023
1 parent 95bc69a commit e8ad17d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions arch/riscv/kvm/tlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down

0 comments on commit e8ad17d

Please sign in to comment.