[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH v6 11/12] qed: Implement .bdrv_drain
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-block] [PATCH v6 11/12] qed: Implement .bdrv_drain |
Date: |
Thu, 22 Oct 2015 12:53:45 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Am 22.10.2015 um 08:32 hat Fam Zheng geschrieben:
> The "need_check_timer" is used to clear the "NEED_CHECK" flag in the
> image header after a grace period once metadata update has finished. In
> compliance to the bdrv_drain semantics we should make sure it remains
> deleted once .bdrv_drain is called.
>
> We cannot reuse qed_need_check_timer_cb because it calls bdrv_aio_flush
> with a completion callback that starts more I/O, bdrv_drain cannot cope
> with this.
For the record: I discussed this with Fam on IRC and we came to the
conclusion that we should instead fix bdrv_drain() to correctly drain
in-flight flushes.
In order to achieve this, Fam will send a series that adds a
BdrvTrackedRequest to all remaining asynchronous operations. So far we
have identified flush, discard and aio_ioctl. At the same time he will
send a rebased version of this series that goes back to asynchronous
flushing in bdrv_qed_drain().
> Also the assertions in qed_need_check_timer_cb and
> qed_unplug_allocating_write_reqs are not guaranteed in the case of
> bdrv_qed_drain.
>
> Signed-off-by: Fam Zheng <address@hidden>
Kevin
- [Qemu-block] [PATCH v6 04/12] aio: introduce aio_{disable, enable}_external, (continued)
- [Qemu-block] [PATCH v6 04/12] aio: introduce aio_{disable, enable}_external, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 05/12] block: Introduce "drained begin/end" API, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 06/12] block: Add "drained begin/end" for transactional external snapshot, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 07/12] block: Add "drained begin/end" for transactional backup, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 08/12] block: Add "drained begin/end" for transactional blockdev-backup, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 09/12] block: Add "drained begin/end" for internal snapshot, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 10/12] block: Introduce BlockDriver.bdrv_drain callback, Fam Zheng, 2015/10/22
- [Qemu-block] [PATCH v6 11/12] qed: Implement .bdrv_drain, Fam Zheng, 2015/10/22
- Re: [Qemu-block] [PATCH v6 11/12] qed: Implement .bdrv_drain,
Kevin Wolf <=
- [Qemu-block] [PATCH v6 12/12] tests: Add test case for aio_disable_external, Fam Zheng, 2015/10/22