On Tue, 2018-12-18 at 06:27 -0700, Jens Axboe wrote:
On 12/18/18 3:32 AM, Benny Halevy wrote:
quoted
On Thu, 2018-12-13 at 10:56 -0700, Jens Axboe wrote:
quoted
Add polled variants of PREAD/PREADV and PWRITE/PWRITEV. These act
like their non-polled counterparts, except we expect to poll for
completion of them. The polling happens at io_getevent() time, and
works just like non-polled IO.
To setup an io_context for polled IO, the application must call
io_setup2() with IOCTX_FLAG_IOPOLL as one of the flags. It is illegal
to mix and match polled and non-polled IO on an io_context.
Polled IO doesn't support the user mapped completion ring. Events
must be reaped through the io_getevents() system call. For non-irq
driven poll devices, there's no way to support completion reaping
from userspace by just looking at the ring. The application itself
is the one that pulls completion entries.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Looks good to me, thanks.
Is that a reviewed-by?
Yes.
Reviewed-by: Benny Halevy <redacted>