Re: [PATCH 08/32] aio: replace kiocb_set_cancel_fn with a cancel_kiocb file operation

2018-05-19 Thread Al Viro
On Tue, May 15, 2018 at 09:48:09PM +0200, Christoph Hellwig wrote: > case -EIOCBQUEUED: > + if (req->ki_filp->f_op->cancel_kiocb) { > + struct aio_kiocb *iocb = > + container_of(req, struct aio_kiocb, rw); > + st

[PATCH 08/32] aio: replace kiocb_set_cancel_fn with a cancel_kiocb file operation

2018-05-15 Thread Christoph Hellwig
The current kiocb_set_cancel_fn implementation assumes the kiocb is embedded into an aio_kiocb, which is fundamentally unsafe as it might have been submitted by non-aio callers. Instead add a cancel_kiocb file operation that replaced the ki_cancel function pointer set by kiocb_set_cancel_fn, and o

[PATCH 08/32] aio: replace kiocb_set_cancel_fn with a cancel_kiocb file operation

2018-05-11 Thread Christoph Hellwig
The current kiocb_set_cancel_fn implementation assumes the kiocb is embedded into an aio_kiocb, which is fundamentally unsafe as it might have been submitted by non-aio callers. Instead add a cancel_kiocb file operation that replaced the ki_cancel function pointer set by kiocb_set_cancel_fn, and o

Re: [PATCH 08/32] aio: replace kiocb_set_cancel_fn with a cancel_kiocb file operation

2018-04-05 Thread Al Viro
On Fri, Mar 30, 2018 at 05:07:45PM +0200, Christoph Hellwig wrote: > The current kiocb_set_cancel_fn implementation assumes the kiocb is > embedded into an aio_kiocb, which is fundamentally unsafe as it might > have been submitted by non-aio callers. Instead add a cancel_kiocb > file operation tha

[PATCH 08/32] aio: replace kiocb_set_cancel_fn with a cancel_kiocb file operation

2018-03-30 Thread Christoph Hellwig
The current kiocb_set_cancel_fn implementation assumes the kiocb is embedded into an aio_kiocb, which is fundamentally unsafe as it might have been submitted by non-aio callers. Instead add a cancel_kiocb file operation that replaced the ki_cancel function pointer set by kiocb_set_cancel_fn, and o