Since early days of OP_POLL_*, we had kernel commit c5de00366e3e ("io_uring: move poll update into remove not add"), which disabled poll update in the POLL_ADD path and moved it to POLL_REMOVE. This updates the man page to reflect that change. Closes: https://github.com/axboe/liburing/pull/1095 Signed-off-by: Gabriel Krisman Bertazi <krisman@xxxxxxx> --- man/io_uring_enter.2 | 48 ++++++++++++++++++-------------------------- 1 file changed, 20 insertions(+), 28 deletions(-) diff --git a/man/io_uring_enter.2 b/man/io_uring_enter.2 index 7d04d47..ab73d54 100644 --- a/man/io_uring_enter.2 +++ b/man/io_uring_enter.2 @@ -302,6 +302,24 @@ the original request. If this flag isn't set on completion, then the poll request has been terminated and no further events will be generated. This mode is available since 5.13. +This command works like +an async +.BR poll(2) +and the completion event result is the returned mask of events. +.TP +.B IORING_OP_POLL_REMOVE +Remove or update an existing poll request. If found, the +.I res +field of the +.I "struct io_uring_cqe" +will contain 0. If not found, +.I res +will contain +.B -ENOENT, +or +.B -EALREADY +if the poll request was in the process of completing already. + If .B IORING_POLL_UPDATE_EVENTS is set in the SQE @@ -311,8 +329,7 @@ events passed in with this request. The lookup is based on the .I user_data field of the original SQE submitted, and this values is passed in the .I addr -field of the SQE. This mode is available since 5.13. - +field of the SQE. If .B IORING_POLL_UPDATE_USER_DATA is set in the SQE @@ -321,32 +338,7 @@ field, then the request will update the .I user_data of an existing poll request based on the value passed in the .I off -field. This mode is available since 5.13. - -This command works like -an async -.BR poll(2) -and the completion event result is the returned mask of events. For the -variants that update -.I user_data -or -.I events -, the completion result will be similar to -.B IORING_OP_POLL_REMOVE. - -.TP -.B IORING_OP_POLL_REMOVE -Remove an existing poll request. If found, the -.I res -field of the -.I "struct io_uring_cqe" -will contain 0. If not found, -.I res -will contain -.B -ENOENT, -or -.B -EALREADY -if the poll request was in the process of completing already. +field. Updating an existing poll is available since 5.13. .TP .B IORING_OP_EPOLL_CTL -- 2.44.0