aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcelo Tosatti <mtosatti@redhat.com>2010-05-04 09:45:21 -0300
committerMarcelo Tosatti <mtosatti@redhat.com>2010-05-11 14:02:22 -0300
commit1fbb22e5f8be9f7793251e5258b23936643f677c (patch)
treee5a4f6ef482a952b56c9c82f188c9e65b1a624b9
parent1a28cac3161f8a85ee0256776068eaed2da025e5 (diff)
standardize on qemu_cpu_kick for signalling cpu thread(s)
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com> Signed-off-by: Avi Kivity <avi@redhat.com>
-rw-r--r--cpus.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/cpus.c b/cpus.c
index 53226b3d90..5afdb4ad7b 100644
--- a/cpus.c
+++ b/cpus.c
@@ -454,8 +454,7 @@ void qemu_cpu_kick(void *_env)
{
CPUState *env = _env;
qemu_cond_broadcast(env->halt_cond);
- if (kvm_enabled())
- qemu_thread_signal(env->thread, SIG_IPI);
+ qemu_thread_signal(env->thread, SIG_IPI);
}
int qemu_cpu_self(void *_env)
@@ -583,7 +582,6 @@ void pause_all_vcpus(void)
while (penv) {
penv->stop = 1;
- qemu_thread_signal(penv->thread, SIG_IPI);
qemu_cpu_kick(penv);
penv = (CPUState *)penv->next_cpu;
}
@@ -592,7 +590,7 @@ void pause_all_vcpus(void)
qemu_cond_timedwait(&qemu_pause_cond, &qemu_global_mutex, 100);
penv = first_cpu;
while (penv) {
- qemu_thread_signal(penv->thread, SIG_IPI);
+ qemu_cpu_kick(penv);
penv = (CPUState *)penv->next_cpu;
}
}
@@ -605,7 +603,6 @@ void resume_all_vcpus(void)
while (penv) {
penv->stop = 0;
penv->stopped = 0;
- qemu_thread_signal(penv->thread, SIG_IPI);
qemu_cpu_kick(penv);
penv = (CPUState *)penv->next_cpu;
}