summaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
authorweiping zhang <zhangweiping@didichuxing.com>2018-01-20 07:34:25 +0800
committerJens Axboe <axboe@kernel.dk>2018-01-19 21:10:20 -0700
commit475a055e62a1eb92f4358ad8a9059df973c190ac (patch)
treee020ba3697a07018d72c5a10a6470c8baa03bb1a /block
parentf5ced52aaa5494c1feb9f80252cb2a2cde0dace8 (diff)
downloadlinux-stable-475a055e62a1eb92f4358ad8a9059df973c190ac.tar.gz
linux-stable-475a055e62a1eb92f4358ad8a9059df973c190ac.tar.bz2
linux-stable-475a055e62a1eb92f4358ad8a9059df973c190ac.zip
blk-throttle: use queue_is_rq_based
use queue_is_rq_based instead of open code. Signed-off-by: weiping zhang <zhangweiping@didichuxing.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block')
-rw-r--r--block/blk-throttle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk-throttle.c b/block/blk-throttle.c
index e136f5ef9577..c475f0fe3530 100644
--- a/block/blk-throttle.c
+++ b/block/blk-throttle.c
@@ -2489,7 +2489,7 @@ void blk_throtl_register_queue(struct request_queue *q)
td->throtl_slice = DFL_THROTL_SLICE_HD;
#endif
- td->track_bio_latency = !q->mq_ops && !q->request_fn;
+ td->track_bio_latency = !queue_is_rq_based(q);
if (!td->track_bio_latency)
blk_stat_enable_accounting(q);
}