summaryrefslogtreecommitdiff
path: root/io_uring/net.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2023-02-21 00:53:39 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2023-02-21 00:53:39 +0300
commitcce5fe5eda0581363a9c585dabf8a5923f15a708 (patch)
tree1de4a7d3b67de40b68ae1764d3ed7631783e5bb9 /io_uring/net.c
parenteca3a04f140a7380d8a7b4cd89d681706a69380c (diff)
parent7d3fd88d61a41016da01889f076fd1c60c7298fc (diff)
downloadlinux-cce5fe5eda0581363a9c585dabf8a5923f15a708.tar.xz
Merge tag 'for-6.3/io_uring-2023-02-16' of git://git.kernel.dk/linux
Pull io_uring updates from Jens Axboe: - Cleanup series making the async prep and handling of REQ_F_FORCE_ASYNC easier to follow and verify (Dylan) - Enable specifying specific flags for OP_MSG_RING (Breno) - Enable use of KASAN with the internal request cache (Breno) - Split the opcode definition structs into a hot and cold part (Breno) - OP_MSG_RING fixes (Pavel, me) - Fix an issue with IOPOLL cancelation and PREEMPT_NONE (me) - Handle TIF_NOTIFY_RESUME for the io-wq threads that never return to userspace (me) - Add support for using io_uring_register() with a registered ring fd (Josh) - Improve handling of poll on the ring fd (Pavel) - Series improving the task_work handling (Pavel) - Misc cleanups, fixes, improvements (Dmitrii, Quanfa, Richard, Pavel, me) * tag 'for-6.3/io_uring-2023-02-16' of git://git.kernel.dk/linux: (51 commits) io_uring: Support calling io_uring_register with a registered ring fd io_uring,audit: don't log IORING_OP_MADVISE io_uring: mark task TASK_RUNNING before handling resume/task work io_uring: always go async for unsupported open flags io_uring: always go async for unsupported fadvise flags io_uring: for requests that require async, force it io_uring: if a linked request has REQ_F_FORCE_ASYNC then run it async io_uring: add reschedule point to handle_tw_list() io_uring: add a conditional reschedule to the IOPOLL cancelation loop io_uring: return normal tw run linking optimisation io_uring: refactor tctx_task_work io_uring: refactor io_put_task helpers io_uring: refactor req allocation io_uring: improve io_get_sqe io_uring: kill outdated comment about overflow flush io_uring: use user visible tail in io_uring_poll() io_uring: pass in io_issue_def to io_assign_file() io_uring: Enable KASAN for request cache io_uring: handle TIF_NOTIFY_RESUME when checking for task_work io_uring/msg-ring: ensure flags passing works for task_work completions ...
Diffstat (limited to 'io_uring/net.c')
-rw-r--r--io_uring/net.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/io_uring/net.c b/io_uring/net.c
index 90326b279965..aeb1d016e2e9 100644
--- a/io_uring/net.c
+++ b/io_uring/net.c
@@ -90,6 +90,7 @@ int io_shutdown_prep(struct io_kiocb *req, const struct io_uring_sqe *sqe)
return -EINVAL;
shutdown->how = READ_ONCE(sqe->len);
+ req->flags |= REQ_F_FORCE_ASYNC;
return 0;
}
@@ -99,8 +100,7 @@ int io_shutdown(struct io_kiocb *req, unsigned int issue_flags)
struct socket *sock;
int ret;
- if (issue_flags & IO_URING_F_NONBLOCK)
- return -EAGAIN;
+ WARN_ON_ONCE(issue_flags & IO_URING_F_NONBLOCK);
sock = sock_from_file(req->file);
if (unlikely(!sock))