summaryrefslogtreecommitdiff
path: root/.rustfmt.toml
diff options
context:
space:
mode:
authorPavel Begunkov <asml.silence@gmail.com>2022-12-07 08:50:01 -0700
committerJens Axboe <axboe@kernel.dk>2022-12-07 08:51:08 -0700
commitf66f73421f0a929734bb41dde575e6d7859e548f (patch)
tree51e49f7b56ce259e8dc755471e3359549774b7c7 /.rustfmt.toml
parent6d043ee1164ca3305738131f170e560587070fa9 (diff)
io_uring: skip spinlocking for ->task_complete
->task_complete was added to serialised CQE posting by doing it from the task context only (or fallback wq when the task is dead), and now we can use that to avoid taking ->completion_lock while filling CQ entries. The patch skips spinlocking only in two spots, __io_submit_flush_completions() and flushing in io_aux_cqe, it's safer and covers all cases we care about. Extra care is taken to force taking the lock while queueing overflow entries. It fundamentally relies on SINGLE_ISSUER to have only one task posting events. It also need to take into account overflowed CQEs, flushing of which happens in the cq wait path, and so this implementation also needs DEFER_TASKRUN to limit waiters. For the same reason we disable it for SQPOLL, and for IOPOLL as it won't benefit from it in any case. DEFER_TASKRUN, SQPOLL and IOPOLL requirement may be relaxed in the future. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/2a8c91fd82cfcdcc1d2e5bac7051fe2c183bda73.1670384893.git.asml.silence@gmail.com [axboe: modify to apply] Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to '.rustfmt.toml')
0 files changed, 0 insertions, 0 deletions