aboutsummaryrefslogtreecommitdiff
path: root/arch/riscv/kernel
diff options
context:
space:
mode:
authorGravatar Clément Léger <cleger@rivosinc.com> 2024-02-21 09:31:06 +0100
committerGravatar Palmer Dabbelt <palmer@rivosinc.com> 2024-04-28 14:50:38 -0700
commit63f93a3ca891fd90353cf81f5d2fc4cbc3508f1a (patch)
tree0ac58a9ea623c45db680fde97a110db564fe308f /arch/riscv/kernel
parentriscv: misaligned: remove CONFIG_RISCV_M_MODE specific code (diff)
downloadlinux-63f93a3ca891fd90353cf81f5d2fc4cbc3508f1a.tar.gz
linux-63f93a3ca891fd90353cf81f5d2fc4cbc3508f1a.tar.bz2
linux-63f93a3ca891fd90353cf81f5d2fc4cbc3508f1a.zip
riscv: hwprobe: export Zihintpause ISA extension
Export the Zihintpause ISA extension through hwprobe which allows using "pause" instructions. Some userspace applications (OpenJDK for instance) uses this to handle some locking back-off. Signed-off-by: Clément Léger <cleger@rivosinc.com> Reviewed-by: Atish Patra <atishp@rivosinc.com> Link: https://lore.kernel.org/r/20240221083108.1235311-1-cleger@rivosinc.com Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Diffstat (limited to 'arch/riscv/kernel')
-rw-r--r--arch/riscv/kernel/sys_hwprobe.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/riscv/kernel/sys_hwprobe.c b/arch/riscv/kernel/sys_hwprobe.c
index 8cae41a502dd..969ef3d59dbe 100644
--- a/arch/riscv/kernel/sys_hwprobe.c
+++ b/arch/riscv/kernel/sys_hwprobe.c
@@ -111,6 +111,7 @@ static void hwprobe_isa_ext0(struct riscv_hwprobe *pair,
EXT_KEY(ZTSO);
EXT_KEY(ZACAS);
EXT_KEY(ZICOND);
+ EXT_KEY(ZIHINTPAUSE);
if (has_vector()) {
EXT_KEY(ZVBB);