Skip to contentSkip to conversation

man/io_uring_submit*.3: Point to error code documentation

PATCH New Gabriel Krisman Bertazi 1 participant 1 message Aug 5 io_uring

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 man/io_uring_submit*.3: Point to error code documentation

There's an open issue in gh asking about the possible error codes returned by io_uring_submit. Add pointers to io_uring_enter(2) in all io_uring_submit* variants where the error codes are explained in detail. The minor exception are _wait_timeout, wait_and_reg and wait_min_timeout, where there are more error codes to be described.

---
 man/io_uring_submit.3                      |  7 ++++++-
 man/io_uring_submit_and_get_events.3       |  7 ++++++-
 man/io_uring_submit_and_wait.3             |  7 ++++++-
 man/io_uring_submit_and_wait_min_timeout.3 | 11 +++++++----
 man/io_uring_submit_and_wait_reg.3         |  7 +++++--
 man/io_uring_submit_and_wait_timeout.3     | 15 ++++++++++-----
 6 files changed, 40 insertions(+), 14 deletions(-)
man/io_uring_submit.3 +6 -1
index c7dbbed2..b78f0e63 100644
@@ -33,6 +33,10 @@ about how many submission queue entries have been successfully submitted, while
 using SQPOLL, the user must fall back to repeatedly submitting a single submission
 queue entry. On failure it returns
 .BR -errno .
+See
+.BR io_uring_enter (2)
+for details on the possible error codes returned by
+.BR io_uring_submit (3) .
 .SH NOTES
 For any request that passes in data in a struct, that data must remain
 valid until the request has been successfully submitted. It need not remain
@@ -48,4 +52,5 @@ mentioning this fact as well, if required for the given command.
 .SH SEE ALSO
 .BR io_uring_get_sqe (3),
 .BR io_uring_submit_and_wait (3),
-.BR io_uring_submit_and_wait_timeout (3)
+.BR io_uring_submit_and_wait_timeout (3),
+.BR io_uring_enter (2)
man/io_uring_submit_and_get_events.3 +6 -1
index 9e143d1d..a30d7966 100644
@@ -26,6 +26,11 @@ On success
 .BR io_uring_submit_and_get_events (3)
 returns the number of submitted submission queue entries. On failure it returns
 .BR -errno .
+See
+.BR io_uring_enter (2)
+for details on the possible error codes returned by
+.BR io_uring_submit_and_get_events (3) .
 .SH SEE ALSO
 .BR io_uring_submit (3),
-.BR io_uring_get_events (3)
+.BR io_uring_get_events (3),
+.BR io_uring_enter (2)
man/io_uring_submit_and_wait.3 +6 -1
index 2351f335..4a642875 100644
@@ -37,8 +37,13 @@ On success
 .BR io_uring_submit_and_wait (3)
 returns the number of submitted submission queue entries. On failure it returns
 .BR -errno .
+See
+.BR io_uring_enter (2)
+for details on the possible error codes returned by
+.BR io_uring_submit_and_wait (3) .
 .SH SEE ALSO
 .BR io_uring_queue_init_params (3),
 .BR io_uring_get_sqe (3),
 .BR io_uring_submit (3),
-.BR io_uring_submit_and_wait_timeout (3)
+.BR io_uring_submit_and_wait_timeout (3),
+.BR io_uring_enter (2)
man/io_uring_submit_and_wait_min_timeout.3 +7 -4
index 6a52806f..1812809f 100644
@@ -106,14 +106,17 @@ returns the number of submitted submission queue entries. On failure it returns
 If the kernel doesn't support this functionality,
 .BR -EINVAL
 will be returned. See note on the feature flag.
-The most common failure case is not receiving a completion within the specified
-timeout,
+See
+.BR io_uring_enter (2)
+for details on the other possible error codes.  In addition to those, this
+function can also return
 .B -ETIME
-is returned in this case.
+if a completion was not received within the specified timeframe.
 .SH SEE ALSO
 .BR io_uring_queue_init_params (3),
 .BR io_uring_get_sqe (3),
 .BR io_uring_submit (3),
 .BR io_uring_submit_and_wait (3),
 .BR io_uring_submit_and_wait_timeout (3),
-.BR io_uring_wait_cqe (3)
+.BR io_uring_wait_cqe (3),
+.BR io_uring_enter (2)
man/io_uring_submit_and_wait_reg.3 +5 -2
index fc0bd76a..f82e432a 100644
@@ -56,9 +56,12 @@ If the kernel doesn't support this functionality,
 will be returned. If no events are submitted and the wait operation times
 out, then
 .BR -ETIME
-will be returned.
+will be returned.  Otherwise, see
+.BR io_uring_enter (2)
+for details on the remaining possible error codes.
 
 .SH SEE ALSO
 .BR io_uring_register_region (3) ,
 .BR io_uring_submit_and_wait_min_timeout (3) ,
-.BR io_uring_submit_and_wait_timeout (3)
+.BR io_uring_submit_and_wait_timeout (3) ,
+.BR io_uring_enter (2)
man/io_uring_submit_and_wait_timeout.3 +10 -5
index 74611766..20fe03ae 100644
@@ -60,15 +60,20 @@ On success
 .BR io_uring_submit_and_wait_timeout (3)
 returns the number of submitted submission queue entries. On failure it returns
 .BR -errno .
+See
+.BR io_uring_enter (2)
+for details on the possible error codes.  In addition to those, this
+function can also return
+.B -ETIME
+if a completion was not received within the specified timeframe, or
+.B -EAGAIN
+if the queue was full and it couldn't queue the timeout request.
 Note that in earlier versions of the liburing library, the return value was 0
 on success.
-The most common failure case is not receiving a completion within the specified
-timeout,
-.B -ETIME
-is returned in this case.
 .SH SEE ALSO
 .BR io_uring_queue_init_params (3),
 .BR io_uring_get_sqe (3),
 .BR io_uring_submit (3),
 .BR io_uring_submit_and_wait (3),
-.BR io_uring_wait_cqe (3)
+.BR io_uring_wait_cqe (3),
+.BR io_uring_enter (2)
Signature · 1 line
2.55.0