]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: fix sequence logic for timeout requests
authorJens Axboe <axboe@kernel.dk>
Fri, 11 Oct 2019 03:42:58 +0000 (21:42 -0600)
committerJens Axboe <axboe@kernel.dk>
Fri, 11 Oct 2019 03:42:58 +0000 (21:42 -0600)
commita571385853ee89b6cb4d6341388f0c2ffd1b7e58
tree597a5b5135c729f046493e2da0c74d4378058014
parente741b241236f652d52046be10cb58ab1a104b3cd
io_uring: fix sequence logic for timeout requests

We have two ways a request can be deferred:

1) It's a regular request that depends on another one
2) It's a timeout that tracks completions

We have a shared helper to determine whether to defer, and that
attempts to make the right decision based on the request. But we
only have some of this information in the caller. Un-share the
two timeout/defer helpers so the caller can use the right one.

Fixes: 3b6f9cc3b110 ("io_uring: IORING_OP_TIMEOUT support")
Reported-by: yangerkun <yangerkun@huawei.com>
Reviewed-by: Jackie Liu <liuyun01@kylinos.cn>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c