commit | eeb60b9ab4000d20261973642dfc9fb0e4b5d073 | [log] [tgz] |
---|---|---|
author | Pavel Begunkov <asml.silence@gmail.com> | Thu Feb 04 13:51:58 2021 +0000 |
committer | Jens Axboe <axboe@kernel.dk> | Thu Feb 04 08:05:46 2021 -0700 |
tree | fc4101dcc7c860897ea716bc08693eee49ecdc25 | |
parent | c1d5a224683b333ddbe278e455d639ccd4f5ca2b [diff] |
io_uring: refactor io_cqring_wait It's easy to make a mistake in io_cqring_wait() because for all break/continue clauses we need to watch for prepare/finish_wait to be used correctly. Extract all those into a new helper io_cqring_wait_schedule(), and transforming the loop into simple series of func calls: prepare(); check_and_schedule(); finish(); Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>