Skip to content

Commit f943ebe

Browse files
committed
RISC-V: KVM: Allow Ztso extension for Guest/VM
Extend the KVM ISA extension ONE_REG interface to allow KVM user space to detect and enable Ztso extension for Guest/VM. Signed-off-by: Anup Patel <apatel@ventanamicro.com> Reviewed-by: Andrew Jones <ajones@ventanamicro.com> Signed-off-by: Anup Patel <anup@brainfault.org>
1 parent d808f0b commit f943ebe

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

arch/riscv/include/uapi/asm/kvm.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ enum KVM_RISCV_ISA_EXT_ID {
166166
KVM_RISCV_ISA_EXT_ZVFH,
167167
KVM_RISCV_ISA_EXT_ZVFHMIN,
168168
KVM_RISCV_ISA_EXT_ZFA,
169+
KVM_RISCV_ISA_EXT_ZTSO,
169170
KVM_RISCV_ISA_EXT_MAX,
170171
};
171172

arch/riscv/kvm/vcpu_onereg.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ static const unsigned long kvm_isa_ext_arr[] = {
6666
KVM_ISA_EXT_ARR(ZKSED),
6767
KVM_ISA_EXT_ARR(ZKSH),
6868
KVM_ISA_EXT_ARR(ZKT),
69+
KVM_ISA_EXT_ARR(ZTSO),
6970
KVM_ISA_EXT_ARR(ZVBB),
7071
KVM_ISA_EXT_ARR(ZVBC),
7172
KVM_ISA_EXT_ARR(ZVFH),
@@ -141,6 +142,7 @@ static bool kvm_riscv_vcpu_isa_disable_allowed(unsigned long ext)
141142
case KVM_RISCV_ISA_EXT_ZKSED:
142143
case KVM_RISCV_ISA_EXT_ZKSH:
143144
case KVM_RISCV_ISA_EXT_ZKT:
145+
case KVM_RISCV_ISA_EXT_ZTSO:
144146
case KVM_RISCV_ISA_EXT_ZVBB:
145147
case KVM_RISCV_ISA_EXT_ZVBC:
146148
case KVM_RISCV_ISA_EXT_ZVFH:

0 commit comments

Comments
 (0)