reenable vm_clock when resuming all vcpus

We disable vm_clock when pausing all vcpus, but we forget to
reenable it when resuming all vcpus. It will cause that the
guest can not be rebooted.

Tested-by: Zhi Yong Wu <zwu.kernel@gmai.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
Wen Congyang 2011-11-04 10:45:58 +08:00 committed by Anthony Liguori
parent f67ab77a43
commit 47113ab6b8

1
cpus.c
View File

@ -891,6 +891,7 @@ void resume_all_vcpus(void)
{ {
CPUState *penv = first_cpu; CPUState *penv = first_cpu;
qemu_clock_enable(vm_clock, true);
while (penv) { while (penv) {
penv->stop = 0; penv->stop = 0;
penv->stopped = 0; penv->stopped = 0;