summaryrefslogtreecommitdiff
path: root/ipc
diff options
context:
space:
mode:
authorXiaoguang Wang <xiaoguang.wang@linux.alibaba.com>2020-02-22 14:46:05 +0800
committerJens Axboe <axboe@kernel.dk>2020-02-22 07:45:03 -0700
commitc7849be9cc2dd2754c48ddbaca27c2de6d80a95d (patch)
treef097b2326d01be9834bcad66d20b1818464db2f1 /ipc
parent7143b5ac5750f404ff3a594b34fdf3fc2f99f828 (diff)
io_uring: fix __io_iopoll_check deadlock in io_sq_threadio_uring-5.6-2020-02-22
Since commit a3a0e43fd770 ("io_uring: don't enter poll loop if we have CQEs pending"), if we already events pending, we won't enter poll loop. In case SETUP_IOPOLL and SETUP_SQPOLL are both enabled, if app has been terminated and don't reap pending events which are already in cq ring, and there are some reqs in poll_list, io_sq_thread will enter __io_iopoll_check(), and find pending events, then return, this loop will never have a chance to exit. I have seen this issue in fio stress tests, to fix this issue, let io_sq_thread call io_iopoll_getevents() with argument 'min' being zero, and remove __io_iopoll_check(). Fixes: a3a0e43fd770 ("io_uring: don't enter poll loop if we have CQEs pending") Signed-off-by: Xiaoguang Wang <xiaoguang.wang@linux.alibaba.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'ipc')
0 files changed, 0 insertions, 0 deletions