On Tue, Dec 03, 2013 at 03:04:01PM +0100, Stefan Hajnoczi wrote:
> On Fri, Nov 22, 2013 at 12:46:16PM +0530, Bharata B Rao wrote:
> > +    qemu_bh_delete(acb->bh);
> > +    acb->bh = NULL;
> > +    qemu_coroutine_enter(acb->coroutine, NULL);
> > +    if (acb->finished) {
> > +        *acb->finished = true;
> > +    }
> 
> Now that aio interfaces are gone ->finished and cancellation can be
> removed.
> 
> > +    qemu_aio_release(acb);
> 
> Please do this in the functions that called qemu_aio_get().  Coroutines
> may yield so it's a little risky to assume the coroutine has finished
> accessing acb.
> > -static BlockDriverAIOCB *qemu_gluster_aio_rw(BlockDriverState *bs,
> > -        int64_t sector_num, QEMUIOVector *qiov, int nb_sectors,
> > -        BlockDriverCompletionFunc *cb, void *opaque, int write)
> > +static coroutine_fn int qemu_gluster_aio_rw(BlockDriverState *bs,
> > +        int64_t sector_num, int nb_sectors, QEMUIOVector *qiov, int write)
> 
> Please rename this to qemu_gluster_co_rw() since it isn't aio anymore
> and doesn't return a BlockDriverAIOCB.

Thanks will address these in v1.

Regards,
Bharata.


Reply via email to