diff options
author | Dylan Yudaken <dylany@fb.com> | 2022-08-30 14:50:09 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2022-09-21 18:30:42 +0200 |
commit | 2327337b881d3f24949da4a4d34a6e657a71a79d (patch) | |
tree | 9d361c8852e2364e713429d6a66a0355d3810cfc /io_uring/io_uring.c | |
parent | io_uring: introduce io_has_work (diff) | |
download | linux-2327337b881d3f24949da4a4d34a6e657a71a79d.tar.xz linux-2327337b881d3f24949da4a4d34a6e657a71a79d.zip |
io_uring: do not run task work at the start of io_uring_enter
This is not needed, and it is normally better to wait for task work until
after submissions. This will allow greater batching if either work arrives
in the meanwhile, or if the submissions cause task work to be queued up.
For SQPOLL this also no longer runs task work, but this is handled inside
the SQPOLL loop anyway.
For IOPOLL io_iopoll_check will run task work anyway
And otherwise io_cqring_wait will run task work
Suggested-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Dylan Yudaken <dylany@fb.com>
Link: https://lore.kernel.org/r/20220830125013.570060-4-dylany@fb.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring/io_uring.c')
-rw-r--r-- | io_uring/io_uring.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/io_uring/io_uring.c b/io_uring/io_uring.c index 471472fe9a56..edf7381b0215 100644 --- a/io_uring/io_uring.c +++ b/io_uring/io_uring.c @@ -2991,8 +2991,6 @@ SYSCALL_DEFINE6(io_uring_enter, unsigned int, fd, u32, to_submit, struct fd f; long ret; - io_run_task_work(); - if (unlikely(flags & ~(IORING_ENTER_GETEVENTS | IORING_ENTER_SQ_WAKEUP | IORING_ENTER_SQ_WAIT | IORING_ENTER_EXT_ARG | IORING_ENTER_REGISTERED_RING))) |