summaryrefslogtreecommitdiff
path: root/hw/xtensa_pic.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/xtensa_pic.c')
-rw-r--r--hw/xtensa_pic.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/xtensa_pic.c b/hw/xtensa_pic.c
index 8b9c0510f9..1ec70cd969 100644
--- a/hw/xtensa_pic.c
+++ b/hw/xtensa_pic.c
@@ -131,7 +131,7 @@ static void xtensa_ccompare_cb(void *opaque)
if (env->halted) {
env->halt_clock = qemu_get_clock_ns(vm_clock);
xtensa_advance_ccount(env, env->wake_ccount - env->sregs[CCOUNT]);
- if (!cpu_has_work(env)) {
+ if (!cpu_has_work(CPU(cpu))) {
env->sregs[CCOUNT] = env->wake_ccount + 1;
xtensa_rearm_ccompare_timer(env);
}