io_uring: add support for IORING_ASYNC_CANCEL_ANY
authorJens Axboe <axboe@kernel.dk>
Mon, 18 Apr 2022 16:44:02 +0000 (10:44 -0600)
committerJens Axboe <axboe@kernel.dk>
Wed, 20 Apr 2022 22:36:10 +0000 (16:36 -0600)
commit7c648b7d6186c59ed3a0e0ae4b774aaf4b415ef2
tree07eb69baba71950fc746de6c33033a2794f1aa6f
parentcd9ef41cd35944899861d3fb708ffcb9db15da7c
io_uring: add support for IORING_ASYNC_CANCEL_ANY

Rather than match on a specific key, be it user_data or file, allow
canceling any request that we can lookup. Works like
IORING_ASYNC_CANCEL_ALL in that it cancels multiple requests, but it
doesn't key off user_data or the file.

Can't be set with IORING_ASYNC_CANCEL_FD, as that's a key selector.
Only one may be used at the time.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
Link: https://lore.kernel.org/r/20220418164402.75259-6-axboe@kernel.dk
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c
include/uapi/linux/io_uring.h