[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 00/11] aio: Introduce handler type to fix nes
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH v2 00/11] aio: Introduce handler type to fix nested aio_poll for dataplane |
Date: |
Wed, 29 Jul 2015 09:38:37 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.0.1 |
On 29/07/2015 06:42, Fam Zheng wrote:
> v2: Switch to disable/enable model. [Paolo]
>
> Most existing nested aio_poll()'s in block layer are inconsiderate of
> dispatching potential new r/w requests from ioeventfds and nbd exports, which
> might result in responsiveness issues (e.g. bdrv_drain_all will not return
> when
> new requests keep coming), or even wrong semantics (e.g. qmp_transaction
> cannot
> enforce atomicity due to aio_poll in bdrv_drain_all).
>
> Previous attampts to address this issue include new op blocker[1],
> bdrv_lock[2]
> and nested AioContext (patches not posted to qemu-devel).
>
> This approach is based on the idea proposed by Paolo Bonzini. The original
> idea
> is introducing "aio_context_disable_client / aio_context_enable_client to
> filter AioContext handlers according to the "client", e.g.
> AIO_CLIENT_DATAPLANE (ioeventfd), AIO_CLIENT_PROTOCOL, AIO_CLIENT_NBD_SERVER,
> AIO_CLIENT_CONTEXT, ... Extend aio_set_{event_notifier,fd}_handler to pass a
> client (type)."
>
> After this series, block layer aio_poll() will only process those "protocol"
> fds that are used in block I/O, plus the ctx->notifier for aio_notify();
> other
> aio_poll()'s keep unchanged.
>
> The biggest advantage over approaches [1] and [2] is, no change is needed in
> virtio-{blk,scsi}-dataplane code, also this doesn't depend on converting QMP
> to
> coroutines.
>
> The windows implementation is not tested except for compiling.
>
> [1]: https://lists.gnu.org/archive/html/qemu-block/2015-05/msg00800.html
> [2]: http://lists.nongnu.org/archive/html/qemu-block/2015-06/msg00027.html
For patches 1-8:
Reviewed-by: Paolo Bonzini <address@hidden>
- [Qemu-devel] [PATCH v2 10/11] block: Replace nested aio_poll with bdrv_aio_poll, (continued)
- [Qemu-devel] [PATCH v2 10/11] block: Replace nested aio_poll with bdrv_aio_poll, Fam Zheng, 2015/07/29
- [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Fam Zheng, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Paolo Bonzini, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Paolo Bonzini, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Fam Zheng, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Paolo Bonzini, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Fam Zheng, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Paolo Bonzini, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Fam Zheng, 2015/07/29
- Re: [Qemu-devel] [PATCH v2 11/11] block: Only poll block layer fds in bdrv_aio_poll, Paolo Bonzini, 2015/07/30
Re: [Qemu-devel] [PATCH v2 00/11] aio: Introduce handler type to fix nested aio_poll for dataplane,
Paolo Bonzini <=