]> git.baikalelectronics.ru Git - kernel.git/commit
io_uring: simplify io_file_get()
authorPavel Begunkov <asml.silence@gmail.com>
Sat, 10 Oct 2020 17:34:08 +0000 (18:34 +0100)
committerJens Axboe <axboe@kernel.dk>
Sat, 10 Oct 2020 18:49:24 +0000 (12:49 -0600)
commit8b6b0e72c64454ecf69fba2a38f3e85c6d3e5730
tree2432657ad83ec5d4e84f928ddc2a633b9094f355
parent88251eac6af594952280182a99ac9282318bb4e1
io_uring: simplify io_file_get()

Keep ->needs_file_no_error check out of io_file_get(), and let callers
handle it. It makes it more straightforward. Also, as the only error it
can hand back -EBADF, make it return a file or NULL.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c