]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix sequencing issues with linked timeouts
authorJens Axboe <axboe@kernel.dk>
Fri, 15 Nov 2019 02:39:52 +0000 (19:39 -0700)
committerJens Axboe <axboe@kernel.dk>
Tue, 26 Nov 2019 02:56:05 +0000 (19:56 -0700)
commitd172e5f0f013c2cc81b1d34992dbadda8d427457
treea6c8d37cacfd6f2574413dee43ab0346883e4d31
parent25a738451235f83bc37549c91fa69addba082883
io_uring: fix sequencing issues with linked timeouts

We have an issue with timeout links that are deeper in the submit chain,
because we only handle it upfront, not from later submissions. Move the
prep + issue of the timeout link to the async work prep handler, and do
it normally for non-async queue. If we validate and prepare the timeout
links upfront when we first see them, there's nothing stopping us from
supporting any sort of nesting.

Fixes: 50036be1ee4a ("io_uring: add support for linked SQE timeouts")
Reported-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c