[dm-devel] [PATCH 6/9] dm: Simplify dm_old_stop_queue()

Bart Van Assche bart.vanassche at sandisk.com
Wed Aug 31 22:17:24 UTC 2016


This patch does not change any functionality.

Signed-off-by: Bart Van Assche <bart.vanassche at sandisk.com>
---
 drivers/md/dm-rq.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c
index 1ca7463..8dc8cfb 100644
--- a/drivers/md/dm-rq.c
+++ b/drivers/md/dm-rq.c
@@ -89,12 +89,8 @@ static void dm_old_stop_queue(struct request_queue *q)
 	unsigned long flags;
 
 	spin_lock_irqsave(q->queue_lock, flags);
-	if (blk_queue_stopped(q)) {
-		spin_unlock_irqrestore(q->queue_lock, flags);
-		return;
-	}
-
-	blk_stop_queue(q);
+	if (!blk_queue_stopped(q))
+		blk_stop_queue(q);
 	spin_unlock_irqrestore(q->queue_lock, flags);
 }
 
-- 
2.9.3




More information about the dm-devel mailing list