Commit aa1a9008 authored by Jens Axboe's avatar Jens Axboe Committed by Cheng Jian
Browse files

io_uring: allow non-fixed files with SQPOLL

mainline inclusion
from mainline-5.11-rc1
commit 28cea78a
category: feature
bugzilla: https://bugzilla.openeuler.org/show_bug.cgi?id=27


CVE: NA
---------------------------

The restriction of needing fixed files for SQPOLL is problematic, and
prevents/inhibits several valid uses cases. With the referenced
files_struct that we have now, it's trivially supportable.

Treat ->files like we do the mm for the SQPOLL thread - grab a reference
to it (and assign it), and drop it when we're done.

This feature is exposed as IORING_FEAT_SQPOLL_NONFIXED.

Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>

Conflicts:
	fs/io_uring.c

Signed-off-by: default avataryangerkun <yangerkun@huawei.com>
Reviewed-by: default avatarzhangyi (F) <yi.zhang@huawei.com>
Signed-off-by: default avatarCheng Jian <cj.chengjian@huawei.com>
parent 47451908
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment