From: Pavel Begunkov asml.silence@gmail.com
mainline inclusion from mainline-5.4-rc3 commit bf7ec93c644cb0064ba7d2fc40d4841c5ba382ab category: feature bugzilla: https://bugzilla.openeuler.org/show_bug.cgi?id=27 CVE: NA ---------------------------
io_queue_link_head() accepts @force_nonblock flag, but io_ring_submit() passes something opposite.
Fixes: c576666863b78 ("io_uring: optimize submit_and_wait API") Reported-by: kbuild test robot lkp@intel.com Signed-off-by: Pavel Begunkov asml.silence@gmail.com Signed-off-by: Jens Axboe axboe@kernel.dk Signed-off-by: Zhihao Cheng chengzhihao1@huawei.com Signed-off-by: yangerkun yangerkun@huawei.com Reviewed-by: zhangyi (F) yi.zhang@huawei.com Signed-off-by: Cheng Jian cj.chengjian@huawei.com --- fs/io_uring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/io_uring.c b/fs/io_uring.c index d78e64d66acc..2c827efa4f53 100644 --- a/fs/io_uring.c +++ b/fs/io_uring.c @@ -2760,7 +2760,7 @@ static int io_ring_submit(struct io_ring_ctx *ctx, unsigned int to_submit,
if (link) io_queue_link_head(ctx, link, &link->submit, shadow_req, - block_for_last); + !block_for_last); if (statep) io_submit_state_end(statep);