/* Enter each coroutine that was previously marked for restart by qemu_co_queue_next() or qemu_co_queue_restart_all(). This function is invoked by the core coroutine code when the current coroutine yields or terminates.  */
void qemu_co_queue_run_restart(Coroutine *co)
/* Enter each coroutine that was previously marked for restart by qemu_co_queue_next() or qemu_co_queue_restart_all(). This function is invoked by the core coroutine code when the current coroutine yields or terminates.  */
void qemu_co_queue_run_restart(Coroutine *co)
{
    Coroutine *next;
    trace_qemu_co_queue_run_restart(co);
    while ((next = QTAILQ_FIRST(&co->co_queue_wakeup))) {
        QTAILQ_REMOVE(&co->co_queue_wakeup, next, co_queue_next);
        qemu_coroutine_enter(next, NULL);
    }
}