summaryrefslogtreecommitdiff
path: root/drivers/md/dm-rq.c
diff options
context:
space:
mode:
authorMing Lei <ming.lei@redhat.com>2020-06-19 11:42:14 +0300
committerMike Snitzer <snitzer@redhat.com>2020-07-20 18:17:42 +0300
commite766668c6cd49d741cfb49eaeb38998ba34d27bc (patch)
tree32cbb6b928ae61335409d593db19655696bcaab6 /drivers/md/dm-rq.c
parent0c248ea27fc88cf8a3035ba0ed75b210be9abf80 (diff)
downloadlinux-e766668c6cd49d741cfb49eaeb38998ba34d27bc.tar.xz
dm rq: don't call blk_mq_queue_stopped() in dm_stop_queue()
dm_stop_queue() only uses blk_mq_quiesce_queue() so it doesn't formally stop the blk-mq queue; therefore there is no point making the blk_mq_queue_stopped() check -- it will never be stopped. In addition, even though dm_stop_queue() actually tries to quiesce hw queues via blk_mq_quiesce_queue(), checking with blk_queue_quiesced() to avoid unnecessary queue quiesce isn't reliable because: the QUEUE_FLAG_QUIESCED flag is set before synchronize_rcu() and dm_stop_queue() may be called when synchronize_rcu() from another blk_mq_quiesce_queue() is in-progress. Fixes: 7b17c2f7292ba ("dm: Fix a race condition related to stopping and starting queues") Signed-off-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-rq.c')
-rw-r--r--drivers/md/dm-rq.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c
index 85e0daabad49..20745e2e34b9 100644
--- a/drivers/md/dm-rq.c
+++ b/drivers/md/dm-rq.c
@@ -70,9 +70,6 @@ void dm_start_queue(struct request_queue *q)
void dm_stop_queue(struct request_queue *q)
{
- if (blk_mq_queue_stopped(q))
- return;
-
blk_mq_quiesce_queue(q);
}