|
@@ -437,6 +437,16 @@ int kvm_unpark_vcpu(KVMState *s, unsigned long vcpu_id)
|
|
|
return kvm_fd;
|
|
|
}
|
|
|
|
|
|
+static void kvm_reset_parked_vcpus(void *param)
|
|
|
+{
|
|
|
+ KVMState *s = param;
|
|
|
+ struct KVMParkedVcpu *cpu;
|
|
|
+
|
|
|
+ QLIST_FOREACH(cpu, &s->kvm_parked_vcpus, node) {
|
|
|
+ kvm_arch_reset_parked_vcpu(cpu->vcpu_id, cpu->kvm_fd);
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
int kvm_create_vcpu(CPUState *cpu)
|
|
|
{
|
|
|
unsigned long vcpu_id = kvm_arch_vcpu_id(cpu);
|
|
@@ -2728,6 +2738,7 @@ static int kvm_init(MachineState *ms)
|
|
|
}
|
|
|
|
|
|
qemu_register_reset(kvm_unpoison_all, NULL);
|
|
|
+ qemu_register_reset(kvm_reset_parked_vcpus, s);
|
|
|
|
|
|
if (s->kernel_irqchip_allowed) {
|
|
|
kvm_irqchip_create(s);
|