[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 01/14] blockjob: Wake up BDS when job becomes id
From: |
Fam Zheng |
Subject: |
Re: [Qemu-devel] [PATCH 01/14] blockjob: Wake up BDS when job becomes idle |
Date: |
Tue, 11 Sep 2018 15:58:54 +0800 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Fri, 09/07 18:15, Kevin Wolf wrote:
> In the context of draining a BDS, the .drained_poll callback of block
> jobs is called. If this returns true (i.e. there is still some activity
> pending), the drain operation may call aio_poll() with blocking=true to
> wait for completion.
>
> As soon as the pending activity is completed and the job finally arrives
> in a quiescent state (i.e. its coroutine either yields with busy=false
> or terminates), the block job must notify the aio_poll() loop to wake
> up, otherwise we get a deadlock if both are running in different
> threads.
>
> Signed-off-by: Kevin Wolf <address@hidden>
Reviewed-by: Fam Zheng <address@hidden>
- [Qemu-devel] [PATCH 00/14] Fix some jobs/drain/aio_poll related hangs, Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 02/14] test-bdrv-drain: Drain with block jobs in an I/O thread, Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 01/14] blockjob: Wake up BDS when job becomes idle, Kevin Wolf, 2018/09/07
- Re: [Qemu-devel] [PATCH 01/14] blockjob: Wake up BDS when job becomes idle,
Fam Zheng <=
- [Qemu-devel] [PATCH 04/14] job: Use AIO_WAIT_WHILE() in job_finish_sync(), Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 07/14] aio-wait: Increase num_waiters even in home thread, Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 03/14] test-blockjob: Acquire AioContext around job_finish_sync(), Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 05/14] test-bdrv-drain: Test AIO_WAIT_WHILE() in completion callback, Kevin Wolf, 2018/09/07
- [Qemu-devel] [PATCH 06/14] block: Add missing locking in bdrv_co_drain_bh_cb(), Kevin Wolf, 2018/09/07