android_kernel_xiaomi_sm8450/io_uring
Pavel Begunkov 208858d4b0 io_uring: always lock in io_apoll_task_func
From: Dylan Yudaken <dylany@meta.com>

[ upstream commit c06c6c5d276707e04cedbcc55625e984922118aa ]

This is required for the failure case (io_req_complete_failed) and is
missing.

The alternative would be to only lock in the failure path, however all of
the non-error paths in io_poll_check_events that do not do not return
IOU_POLL_NO_ACTION end up locking anyway. The only extraneous lock would
be for the multishot poll overflowing the CQE ring, however multishot poll
would probably benefit from being locked as it will allow completions to
be batched.

So it seems reasonable to lock always.

Signed-off-by: Dylan Yudaken <dylany@meta.com>
Link: https://lore.kernel.org/r/20221124093559.3780686-3-dylany@meta.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-09-19 12:20:23 +02:00
..
io_uring.c io_uring: always lock in io_apoll_task_func 2023-09-19 12:20:23 +02:00
io-wq.c io_uring: don't gate task_work run on TIF_NOTIFY_SIGNAL 2023-01-24 07:19:56 +01:00
io-wq.h io_uring: import 5.15-stable io_uring 2023-01-04 11:39:23 +01:00
Makefile io_uring: import 5.15-stable io_uring 2023-01-04 11:39:23 +01:00