Stop current VCPU on synchronous reset requests
authorJan Kiszka <jan.kiszka@siemens.com>
Tue, 1 Feb 2011 21:15:43 +0000 (22:15 +0100)
committerMarcelo Tosatti <mtosatti@redhat.com>
Mon, 14 Feb 2011 14:39:44 +0000 (12:39 -0200)
commitdb07c19131cf4b041972ff3de332deb8d4f6741c
tree3d1c0bb7600ea91eea18e27530c3afa2ec41bbf7
parent30eddf3999cd61d82e283a6889a4971e2d226615
Stop current VCPU on synchronous reset requests

If some I/O operation ends up calling qemu_system_reset_request in VCPU
context, we record this and inform the io-thread, but we do not
terminate the VCPU loop. This can lead to fairly unexpected behavior if
the triggering reset operation is supposed to work synchronously.

Fix this for TCG (when run in deterministic I/O mode) by setting the
VCPU on stop and issuing a cpu_exit. KVM requires some more work on its
VCPU loop.

[ ported from qemu-kvm ]

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
cpus.c
cpus.h
vl.c