io_uring: clear IORING_SQ_NEED_WAKEUP after executing task works
authorXiaoguang Wang <xiaoguang.wang@linux.alibaba.com>
Thu, 23 Jul 2020 12:57:24 +0000 (20:57 +0800)
committerJens Axboe <axboe@kernel.dk>
Fri, 24 Jul 2020 19:00:46 +0000 (13:00 -0600)
commit23b3628e45924419399da48c2b3a522b05557c91
tree6fdaf052da6860b677e544bb031184c949c3955a
parent5af1d13e8f0d8839db04a71ec786f369b0e67234
io_uring: clear IORING_SQ_NEED_WAKEUP after executing task works

In io_sq_thread(), if there are task works to handle, current codes
will skip schedule() and go on polling sq again, but forget to clear
IORING_SQ_NEED_WAKEUP flag, fix this issue. Also add two helpers to
set and clear IORING_SQ_NEED_WAKEUP flag,

Signed-off-by: Xiaoguang Wang <xiaoguang.wang@linux.alibaba.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c