[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 6/9] block: Emulate bdrv_ioctl with bdrv_aio_
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH v2 6/9] block: Emulate bdrv_ioctl with bdrv_aio_ioctl and track both |
Date: |
Thu, 5 Nov 2015 15:59:26 +0000 |
User-agent: |
Mutt/1.5.23 (2015-06-09) |
On Thu, Oct 29, 2015 at 10:14:23AM +0800, Fam Zheng wrote:
> BlockAIOCB *bdrv_aio_ioctl(BlockDriverState *bs,
> unsigned long int req, void *buf,
> BlockCompletionFunc *cb, void *opaque)
> {
> - BlockDriver *drv = bs->drv;
> + BlockAIOCBCoroutine *acb = qemu_aio_get(&bdrv_em_co_aiocb_info,
> + bs, cb, opaque);
> + acb->need_bh = true;
> + acb->req.error = -EINPROGRESS;
> + acb->req.req = req;
> + acb->req.buf = buf;
> + if (qemu_in_coroutine()) {
> + /* Fast-path if already in coroutine context */
> + bdrv_co_aio_ioctl_entry(acb);
This is not how bdrv_aio_*() work. They never use the existing
coroutine and doing so here would be inconsistent.
signature.asc
Description: PGP signature
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Qemu-devel] [PATCH v2 6/9] block: Emulate bdrv_ioctl with bdrv_aio_ioctl and track both,
Stefan Hajnoczi <=