io_uring: fix NULL-mm for linked reqs
authorPavel Begunkov <asml.silence@gmail.com>
Thu, 25 Jun 2020 09:38:13 +0000 (12:38 +0300)
committerJens Axboe <axboe@kernel.dk>
Thu, 25 Jun 2020 13:22:38 +0000 (07:22 -0600)
commitd3cac64c498c4fb2df46b97ee6f4c7d6d75f5e3d
tree69f3c045b16c8612253e619c65b04ba4daab65f1
parentf6b6c7d6a9600bdbf5826f57137630e1670e2d87
io_uring: fix NULL-mm for linked reqs

__io_queue_sqe() tries to handle all request of a link,
so it's not enough to grab mm in io_sq_thread_acquire_mm()
based just on the head.

Don't check req->needs_mm and do it always.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
fs/io_uring.c