Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Darrick J. Wong
On Wed, Apr 02, 2014 at 03:53:33PM -0700, Zach Brown wrote: > > > I'd just remove this generic teardown callback path entirely. If > > > there's PI state hanging off the iocb tear it down during iocb teardown. > > > > Hmm, I thought aio_complete /was/ iocb teardown time. > > Well, usually :). I

Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Zach Brown
> > I'd just remove this generic teardown callback path entirely. If > > there's PI state hanging off the iocb tear it down during iocb teardown. > > Hmm, I thought aio_complete /was/ iocb teardown time. Well, usually :). If you build up before aio_run_iocb() then you nead to teardown in kiocb_

Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Darrick J. Wong
On Wed, Apr 02, 2014 at 12:49:47PM -0700, Zach Brown wrote: > > @@ -916,6 +921,17 @@ void aio_complete(struct kiocb *iocb, long res, long > > res2) > > struct io_event *ev_page, *event; > > unsigned long flags; > > unsigned tail, pos; > > + int ret; > > + > > + ret = io_teardown_

Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Darrick J. Wong
On Wed, Apr 02, 2014 at 03:22:20PM -0400, Jeff Moyer wrote: > "Darrick J. Wong" writes: > > > Define a generic interface to allow userspace to attach metadata to an > > IO operation. This interface will be used initially to implement > > protection information (PI) pass through, though it ought

Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Zach Brown
> @@ -916,6 +921,17 @@ void aio_complete(struct kiocb *iocb, long res, long > res2) > struct io_event *ev_page, *event; > unsigned long flags; > unsigned tail, pos; > + int ret; > + > + ret = io_teardown_extensions(iocb); > + if (ret) { > + if (!res) > +

Re: [PATCH 2/6] io: define an interface for IO extensions

2014-04-02 Thread Jeff Moyer
"Darrick J. Wong" writes: > Define a generic interface to allow userspace to attach metadata to an > IO operation. This interface will be used initially to implement > protection information (PI) pass through, though it ought to be usable > by anyone else desiring to extend the IO interface. It