]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
blk-mq: use blk_mq_rq_state() instead of testing REQ_ATOM_COMPLETE
authorTejun Heo <tj@kernel.org>
Tue, 9 Jan 2018 16:29:49 +0000 (08:29 -0800)
committerJens Axboe <axboe@kernel.dk>
Tue, 9 Jan 2018 16:31:15 +0000 (09:31 -0700)
commit67818d25738b1c9ffb8541ca875b2ae3304869d5
tree915392d429871ac9fe061a00c7f6da9eeb85726e
parent1d9bd5161ba32db5665a617edc8b0723880f543e
blk-mq: use blk_mq_rq_state() instead of testing REQ_ATOM_COMPLETE

blk_mq_check_inflight() and blk_mq_poll_hybrid_sleep() test
REQ_ATOM_COMPLETE to determine the request state.  Both uses are
speculative and we can test REQ_ATOM_STARTED and blk_mq_rq_state() for
equivalent results.  Replace the tests.  This will allow removing
REQ_ATOM_COMPLETE usages from blk-mq.

Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq.c