We don't need to wait for the PDU active list to be empty: virtfs_reset() already takes care of that.
Signed-off-by: Greg Kurz <gr...@kaod.org> --- hw/9pfs/9p.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c index 86ed9065c4e2..16ef6bd5bd8c 100644 --- a/hw/9pfs/9p.c +++ b/hw/9pfs/9p.c @@ -3601,6 +3601,7 @@ static void coroutine_fn virtfs_co_reset(void *opaque) VirtfsCoResetData *data = opaque; virtfs_reset(&data->pdu); + assert(QLIST_EMPTY(&data->pdu.s->active_list)); data->done = true; } @@ -3609,10 +3610,6 @@ void v9fs_reset(V9fsState *s) VirtfsCoResetData data = { .pdu = { .s = s }, .done = false }; Coroutine *co; - while (!QLIST_EMPTY(&s->active_list)) { - aio_poll(qemu_get_aio_context(), true); - } - co = qemu_coroutine_create(virtfs_co_reset, &data); qemu_coroutine_enter(co);