man: fixup description of fixed files I/O

The man page suggests that IOSQE_FIXED_FILE must be specified for all
sqes when the io_uring instance has files registered.  This is not
the case, so clear that up.

Also fix a typo (few->new) while we're in there.

Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
Jeff Moyer
2019-01-25 17:38:51 -05:00
committed by Jens Axboe
parent 2a8e5b105c
commit 9688b4a00f
2 changed files with 12 additions and 13 deletions

View File

@@ -146,13 +146,13 @@ The
.I flags .I flags
field is a bit mask. Currently, the only supported flag is field is a bit mask. Currently, the only supported flag is
.B IOSQE_FIXED_FILE. .B IOSQE_FIXED_FILE.
This flag must be specified for io_uring instances that registered When this flag is specified,
files using the
.BR io_uring_register(2)
system call. When specified,
.I fd .I fd
contains an index into the files array registered with the io_uring is an index into the files array registered with the io_uring instance (see the
instance. .B IORING_REGISTER_FILES
section of the
.BR io_uring_register(2)
man page).
.I ioprio .I ioprio
specifies the I/O priority. See specifies the I/O priority. See

View File

@@ -103,20 +103,19 @@ contains a pointer to an array of
.I nr_args .I nr_args
file descriptors (signed 32 bit integers). file descriptors (signed 32 bit integers).
When used, the application must set To make use of the registered files, the
.B IOSQE_FIXED_FILE .B IOSQE_FIXED_FILE
in the flag must be set in the
.I flags .I flags
member of the member of the
.I struct io_uring_sqe. .I struct io_uring_sqe,
Then, and the
.I fd .I fd
is set to the index of the buffer in the array supplied to member is set to the index of the file in the file descriptor array.
.B IORING_REGISTER_FILES.
Files are automatically unregistered when the io_uring instance is Files are automatically unregistered when the io_uring instance is
torn down. An application need only unregister if it wishes to torn down. An application need only unregister if it wishes to
register a few set of fds. register a new set of fds.
.TP .TP
.BR IORING_UNREGISTER_FILES .BR IORING_UNREGISTER_FILES
This operation requires no argument, and This operation requires no argument, and