[PATCH] LoongArch: KVM: Add KVM_LOONGARCH_VM_FEAT_CRASH feature detect support
From: Bibo Mao
Date: Wed Oct 28 2026 - 23:36:59 EST
Add feature detect with KVM_LOONGARCH_VM_FEAT_CRASH, so that VMM in
user space can detect and enable this feature.
Fixes: 00289c235d40 ("LoongArch: KVM: Add hypercall crash support")
Signed-off-by: Bibo Mao <maobibo@xxxxxxxxxxx>
---
arch/loongarch/kvm/vm.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/loongarch/kvm/vm.c b/arch/loongarch/kvm/vm.c
index e4c1c65fe20b..ba5fdfcd7016 100644
--- a/arch/loongarch/kvm/vm.c
+++ b/arch/loongarch/kvm/vm.c
@@ -165,6 +165,7 @@ static int kvm_vm_feature_has_attr(struct kvm *kvm, struct kvm_device_attr *attr
case KVM_LOONGARCH_VM_FEAT_PV_IPI:
case KVM_LOONGARCH_VM_FEAT_PV_PREEMPT:
case KVM_LOONGARCH_VM_FEAT_PV_STEALTIME:
+ case KVM_LOONGARCH_VM_FEAT_CRASH:
if (kvm_vm_support(&kvm->arch, attr->attr))
return 0;
return -ENXIO;
base-commit: c339f4010dea8b0d754f84ace70cd1b089878ef8
--
2.39.3