WSL2-Linux-Kernel/io_uring
Pavel Begunkov cc6b09671d io_uring: fix drain stalls by invalid SQE
[ Upstream commit cfdbaa3a29 ]

cq_extra is protected by ->completion_lock, which io_get_sqe() misses.
The bug is harmless as it doesn't happen in real life, requires invalid
SQ index array and racing with submission, and only messes up the
userspace, i.e. stall requests execution but will be cleaned up on
ring destruction.

Fixes: 15641e4270 ("io_uring: don't cache number of dropped SQEs")
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/66096d54651b1a60534bb2023f2947f09f50ef73.1691538547.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-09-19 12:22:39 +02:00
..
Makefile
io-wq.c io_uring: don't gate task_work run on TIF_NOTIFY_SIGNAL 2023-01-24 07:22:43 +01:00
io-wq.h
io_uring.c io_uring: fix drain stalls by invalid SQE 2023-09-19 12:22:39 +02:00