Re: [PATCH 5/6] aio: implement IOCB_CMD_FSYNC and IOCB_CMD_FDSYNC

2018-04-05 Thread Al Viro
On Wed, Mar 28, 2018 at 09:26:38AM +0200, Christoph Hellwig wrote: > +static int aio_fsync(struct fsync_iocb *req, struct iocb *iocb, bool > datasync) > +{ > + int ret; > + > + if (iocb->aio_buf) > + return -EINVAL; > + if (iocb->aio_offset || iocb->aio_nbytes || iocb->aio_

[PATCH 5/6] aio: implement IOCB_CMD_FSYNC and IOCB_CMD_FDSYNC

2018-03-28 Thread Christoph Hellwig
Simple workqueue offload for now, but prepared for adding a real aio_fsync method if the need arises. Based on an earlier patch from Dave Chinner. Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman Reviewed-by: Darrick J. Wong --- fs/aio.c | 50 ++