summaryrefslogtreecommitdiff
path: root/cpus.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2011-04-13 10:03:46 +0200
committerEdgar E. Iglesias <edgar.iglesias@gmail.com>2011-04-15 09:27:56 +0200
commit6cc50d9e1f725c7a3551f9fbf35db961898a1f9b (patch)
tree8d79ce50b0e1bbc0548c9584936ca565be75f410 /cpus.c
parent7190601ab7cc9fb03b13e831504a54a1f45fe7ce (diff)
downloadqemu-6cc50d9e1f725c7a3551f9fbf35db961898a1f9b.tar.gz
qemu-6cc50d9e1f725c7a3551f9fbf35db961898a1f9b.tar.bz2
qemu-6cc50d9e1f725c7a3551f9fbf35db961898a1f9b.zip
qemu_next_deadline should not consider host-time timers
It is purely for icount-based virtual timers. And now that we got the code right, rename the function to clarify the intended scope. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Tested-by: Edgar E. Iglesias <edgar.iglesias@gmail.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Diffstat (limited to 'cpus.c')
-rw-r--r--cpus.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cpus.c b/cpus.c
index 6a50199039..1fc34b75c2 100644
--- a/cpus.c
+++ b/cpus.c
@@ -833,7 +833,7 @@ static void *qemu_tcg_cpu_thread_fn(void *arg)
while (1) {
cpu_exec_all();
- if (use_icount && qemu_next_deadline() <= 0) {
+ if (use_icount && qemu_next_icount_deadline() <= 0) {
qemu_notify_event();
}
qemu_tcg_wait_io_event();
@@ -1050,7 +1050,7 @@ static int tcg_cpu_exec(CPUState *env)
qemu_icount -= (env->icount_decr.u16.low + env->icount_extra);
env->icount_decr.u16.low = 0;
env->icount_extra = 0;
- count = qemu_icount_round (qemu_next_deadline());
+ count = qemu_icount_round(qemu_next_icount_deadline());
qemu_icount += count;
decr = (count > 0xffff) ? 0xffff : count;
count -= decr;