aboutsummaryrefslogtreecommitdiff
path: root/qemu-coroutine.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu-coroutine.c')
-rw-r--r--qemu-coroutine.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/qemu-coroutine.c b/qemu-coroutine.c
index 60ac79e680..423430d3a0 100644
--- a/qemu-coroutine.c
+++ b/qemu-coroutine.c
@@ -45,6 +45,7 @@ Coroutine *qemu_coroutine_create(CoroutineEntry *entry)
}
co->entry = entry;
+ QTAILQ_INIT(&co->co_queue_wakeup);
return co;
}
@@ -87,6 +88,8 @@ static void coroutine_swap(Coroutine *from, Coroutine *to)
ret = qemu_coroutine_switch(from, to, COROUTINE_YIELD);
+ qemu_co_queue_run_restart(to);
+
switch (ret) {
case COROUTINE_YIELD:
return;