Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-09 Thread Al Viro
On Fri, Mar 08, 2019 at 03:36:50AM +, Al Viro wrote: > See vfs.git#work.aio; the crucial bits are in these commits: > keep io_event in aio_kiocb > get rid of aio_complete() res/res2 arguments > move aio_complete() to final iocb_put(), try to fix aio_poll() logics > The first

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-08 Thread Christoph Hellwig
On Fri, Mar 08, 2019 at 03:36:50AM +, Al Viro wrote: > See vfs.git#work.aio; the crucial bits are in these commits: > keep io_event in aio_kiocb > get rid of aio_complete() res/res2 arguments > move aio_complete() to final iocb_put(), try to fix aio_poll() logics > The first t

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-07 Thread Al Viro
On Wed, Mar 06, 2019 at 05:30:21PM -0800, Linus Torvalds wrote: > On Wed, Mar 6, 2019 at 5:20 PM Al Viro wrote: > > > > I'll try to massage that series on top of your patch; I still hate the > > post-vfs_poll() logics in aio_poll() ;-/ Give me about half an hour > > and I'll have something to pos

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Linus Torvalds
On Wed, Mar 6, 2019 at 5:20 PM Al Viro wrote: > > I'll try to massage that series on top of your patch; I still hate the > post-vfs_poll() logics in aio_poll() ;-/ Give me about half an hour > and I'll have something to post. No inherent hurry, I sent the ping just to make sure it hadn't gotten

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Al Viro
On Thu, Mar 07, 2019 at 12:48:28AM +, Al Viro wrote: > On Thu, Mar 07, 2019 at 12:41:59AM +, Al Viro wrote: > > On Wed, Mar 06, 2019 at 04:23:04PM -0800, Linus Torvalds wrote: > > > On Wed, Mar 6, 2019 at 4:03 PM Al Viro wrote: > > > > > > > > From: Al Viro > > > > > > > > "aio: remove th

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Al Viro
On Thu, Mar 07, 2019 at 12:41:59AM +, Al Viro wrote: > On Wed, Mar 06, 2019 at 04:23:04PM -0800, Linus Torvalds wrote: > > On Wed, Mar 6, 2019 at 4:03 PM Al Viro wrote: > > > > > > From: Al Viro > > > > > > "aio: remove the extra get_file/fput pair in io_submit_one" was > > > too optimistic -

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Al Viro
On Wed, Mar 06, 2019 at 04:23:04PM -0800, Linus Torvalds wrote: > On Wed, Mar 6, 2019 at 4:03 PM Al Viro wrote: > > > > From: Al Viro > > > > "aio: remove the extra get_file/fput pair in io_submit_one" was > > too optimistic - not dereferencing file pointer after e.g. > > ->write_iter() returns i

Re: [PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Linus Torvalds
On Wed, Mar 6, 2019 at 4:03 PM Al Viro wrote: > > From: Al Viro > > "aio: remove the extra get_file/fput pair in io_submit_one" was > too optimistic - not dereferencing file pointer after e.g. > ->write_iter() returns is not enough; that reference might've been > the only thing that kept alive ob

[PATCH 1/8] aio: make sure file is pinned

2019-03-06 Thread Al Viro
From: Al Viro "aio: remove the extra get_file/fput pair in io_submit_one" was too optimistic - not dereferencing file pointer after e.g. ->write_iter() returns is not enough; that reference might've been the only thing that kept alive objects that are referenced *before* the method returns. Such