aio: add support for submission/completion rings
Experimental support for submitting and completing IO through rings
shared between the application and kernel.
The submission rings are struct iocb, like we would submit through
io_submit(), and the completion rings are struct io_event, like we
would pass in (and copy back) from io_getevents().
A new system call is added for this, io_ring_enter(). This system
call submits IO that is queued in the SQ ring, and/or completes IO
and stores the results in the CQ ring.
This could be augmented with a kernel thread that does the submission
and polling, then the application would never have to enter the
kernel to do IO.
Sample application: http://brick.kernel.dk/snaps/aio-ring.c
Note that we need to (in terms of cleanup/rebase)
1) Bring in the mapped_range support sooner
2) Fold the system call changes (both of them)
Signed-off-by: Jens Axboe <firstname.lastname@example.org>
4 files changed