io_uring: fix poll file assign deadlock
authorPavel Begunkov <asml.silence@gmail.com>
Wed, 13 Apr 2022 15:10:34 +0000 (16:10 +0100)
committerJens Axboe <axboe@kernel.dk>
Wed, 13 Apr 2022 16:25:37 +0000 (10:25 -0600)
commitcce64ef01308b677a687d90927fc2b2e0e1cba67
tree94486edd3f2ff62b930b92ccad513cf7784ea7f8
parente941976659f1f6834077a1596bf53e6bdb10e90b
io_uring: fix poll file assign deadlock

We pass "unlocked" into io_assign_file() in io_poll_check_events(),
which can lead to double locking.

Fixes: 6bf9c47a3989 ("io_uring: defer file assignment")
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/2476d4ae46554324b599ee4055447b105f20a75a.1649862516.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c