[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH RFC v4 5/9] target/loongarch: Implement kvm_arch_init function
From: |
xianglai li |
Subject: |
[PATCH RFC v4 5/9] target/loongarch: Implement kvm_arch_init function |
Date: |
Mon, 9 Oct 2023 17:01:33 +0800 |
From: Tianrui Zhao <zhaotianrui@loongson.cn>
Implement the kvm_arch_init of loongarch, in the function, the
KVM_CAP_MP_STATE cap is checked by kvm ioctl.
Cc: "Michael S. Tsirkin" <mst@redhat.com>
Cc: Cornelia Huck <cohuck@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: "Marc-André Lureau" <marcandre.lureau@redhat.com>
Cc: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: Thomas Huth <thuth@redhat.com>
Cc: "Philippe Mathieu-Daudé" <philmd@linaro.org>
Cc: Richard Henderson <richard.henderson@linaro.org>
Cc: Peter Maydell <peter.maydell@linaro.org>
Cc: Bibo Mao <maobibo@loongson.cn>
Cc: Song Gao <gaosong@loongson.cn>
Cc: Xiaojuan Yang <yangxiaojuan@loongson.cn>
Cc: Tianrui Zhao <zhaotianrui@loongson.cn>
Signed-off-by: Tianrui Zhao <zhaotianrui@loongson.cn>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: xianglai li <lixianglai@loongson.cn>
---
target/loongarch/kvm.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/target/loongarch/kvm.c b/target/loongarch/kvm.c
index 8fda80b107..5e3bda444e 100644
--- a/target/loongarch/kvm.c
+++ b/target/loongarch/kvm.c
@@ -491,6 +491,7 @@ int kvm_arch_get_default_type(MachineState *ms)
int kvm_arch_init(MachineState *ms, KVMState *s)
{
+ cap_has_mp_state = kvm_check_extension(s, KVM_CAP_MP_STATE);
return 0;
}
--
2.39.1
- [PATCH RFC v4 0/9] Add loongarch kvm accel support, xianglai li, 2023/10/09
- [PATCH RFC v4 3/9] target/loongarch: Supplement vcpu env initial when vcpu reset, xianglai li, 2023/10/09
- [PATCH RFC v4 6/9] target/loongarch: Implement kvm_arch_init_vcpu, xianglai li, 2023/10/09
- [PATCH RFC v4 8/9] target/loongarch: Implement set vcpu intr for kvm, xianglai li, 2023/10/09
- [PATCH RFC v4 1/9] linux-headers: Add KVM headers for loongarch, xianglai li, 2023/10/09
- [PATCH RFC v4 5/9] target/loongarch: Implement kvm_arch_init function,
xianglai li <=
- [PATCH RFC v4 4/9] target/loongarch: Implement kvm get/set registers, xianglai li, 2023/10/09
- [PATCH RFC v4 7/9] target/loongarch: Implement kvm_arch_handle_exit, xianglai li, 2023/10/09
- [PATCH RFC v4 2/9] target/loongarch: Define some kvm_arch interfaces, xianglai li, 2023/10/09
- [PATCH RFC v4 9/9] target/loongarch: Add loongarch kvm into meson build, xianglai li, 2023/10/09
- Re: [PATCH RFC v4 0/9] Add loongarch kvm accel support, Philippe Mathieu-Daudé, 2023/10/11