Expected behaviour for device driver aio_read(), aio_write() and (girl)friends?

From: Leon Woestenberg
Date: Mon Jun 15 2009 - 16:48:45 EST


Hello,

as I cannot find any existing drivers using aio_read()/write(), and
the interface has changed since LDD3 now supporting vectored I/O,
where can I get more information on it?

Some questions I came up with:

For a multi vector I/O, can aio_read() still return the number of bytes?
Must it do so for synchronous I/O (either requested or possible) only,
or is returning the queued amount of I/O bytes also valid?
Or, must it still return -EIOCBQUEUED if everything was queued?

For multi-segment vectored IO, what must aio_complete return in res2?
The total of bytes across all completed I/O vectors?
And what if the I/O fails half-way the segments?

LDD3 says the first result of aio_complete() is the "usual result
status" for the operation.
I'm not sure what that is for multi-vectored I/O; I guess the total
amount of bytes transferred?



Regards,
--
Leon
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/