RISC-V: KVM: Allow Zvfh[min] extensions for Guest/VM
We extend the KVM ISA extension ONE_REG interface to allow KVM user space to detect and enable Zvfh[min] extensions 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>
This commit is contained in:
parent
1a3bc50782
commit
f463002859
@ -163,6 +163,8 @@ enum KVM_RISCV_ISA_EXT_ID {
|
||||
KVM_RISCV_ISA_EXT_ZFH,
|
||||
KVM_RISCV_ISA_EXT_ZFHMIN,
|
||||
KVM_RISCV_ISA_EXT_ZIHINTNTL,
|
||||
KVM_RISCV_ISA_EXT_ZVFH,
|
||||
KVM_RISCV_ISA_EXT_ZVFHMIN,
|
||||
KVM_RISCV_ISA_EXT_MAX,
|
||||
};
|
||||
|
||||
|
@ -67,6 +67,8 @@ static const unsigned long kvm_isa_ext_arr[] = {
|
||||
KVM_ISA_EXT_ARR(ZKT),
|
||||
KVM_ISA_EXT_ARR(ZVBB),
|
||||
KVM_ISA_EXT_ARR(ZVBC),
|
||||
KVM_ISA_EXT_ARR(ZVFH),
|
||||
KVM_ISA_EXT_ARR(ZVFHMIN),
|
||||
KVM_ISA_EXT_ARR(ZVKB),
|
||||
KVM_ISA_EXT_ARR(ZVKG),
|
||||
KVM_ISA_EXT_ARR(ZVKNED),
|
||||
@ -139,6 +141,8 @@ static bool kvm_riscv_vcpu_isa_disable_allowed(unsigned long ext)
|
||||
case KVM_RISCV_ISA_EXT_ZKT:
|
||||
case KVM_RISCV_ISA_EXT_ZVBB:
|
||||
case KVM_RISCV_ISA_EXT_ZVBC:
|
||||
case KVM_RISCV_ISA_EXT_ZVFH:
|
||||
case KVM_RISCV_ISA_EXT_ZVFHMIN:
|
||||
case KVM_RISCV_ISA_EXT_ZVKB:
|
||||
case KVM_RISCV_ISA_EXT_ZVKG:
|
||||
case KVM_RISCV_ISA_EXT_ZVKNED:
|
||||
|
Loading…
Reference in New Issue
Block a user