]> git.proxmox.com Git - mirror_qemu.git/commit - cpus.c
Replace qemu_system_cond with VCPU stop mechanism
authorJan Kiszka <jan.kiszka@siemens.com>
Mon, 22 Aug 2011 16:35:25 +0000 (18:35 +0200)
committerAnthony Liguori <aliguori@us.ibm.com>
Mon, 22 Aug 2011 19:37:03 +0000 (14:37 -0500)
commitfa7d1867578b6a1afc39d4ece8629a1e92baddd7
tree4ade5ae34193bff107943c0cf7ec1a4ee34f976a
parent78dd9ff6328eca1aa17fb1bc4d63f30b44ff0b6f
Replace qemu_system_cond with VCPU stop mechanism

We can express the VCPU thread wakeup with the stop mechanism, saving
both qemu_system_ready and the qemu_system_cond. For KVM threads, we can
just enter the main loop as long as the thread is stopped. The central
TCG thread is better held back before the loop as there can be side
effects of the services called even when all CPUs are stopped.

Creating VCPUs in stopped state will also be required for proper CPU
hotplugging support.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
cpus.c