All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shenghui Wang <shhuiw@foxmail.com>
To: axboe@kernel.dk, linux-block@vger.kernel.org
Subject: [PATCH] block: cleanup for blk_cleanup_queue()
Date: Sun,  7 Apr 2019 19:03:14 +0800	[thread overview]
Message-ID: <20190407110314.7145-1-shhuiw@foxmail.com> (raw)

2 small cleanup:
* blk_set_queue_dying(q) has set QUEUE_FLAG_DYING. Remove the redundant
  statement 'blk_queue_flag_set(QUEUE_FLAG_DYING, q)'
* requests queued drained before DEAD marking, not DYING marking.
  Update the comment.

Signed-off-by: Shenghui Wang <shhuiw@foxmail.com>
---
 block/blk-core.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/block/blk-core.c b/block/blk-core.c
index 4673ebe42255..177377becfab 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -334,11 +334,10 @@ void blk_cleanup_queue(struct request_queue *q)
 
 	blk_queue_flag_set(QUEUE_FLAG_NOMERGES, q);
 	blk_queue_flag_set(QUEUE_FLAG_NOXMERGES, q);
-	blk_queue_flag_set(QUEUE_FLAG_DYING, q);
 	mutex_unlock(&q->sysfs_lock);
 
 	/*
-	 * Drain all requests queued before DYING marking. Set DEAD flag to
+	 * Drain all requests queued before DEAD marking. Set DEAD flag to
 	 * prevent that q->request_fn() gets invoked after draining finished.
 	 */
 	blk_freeze_queue(q);
-- 
2.20.1




             reply	other threads:[~2019-04-07 11:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-07 11:03 Shenghui Wang [this message]
2019-04-07 14:18 ` [PATCH] block: cleanup for blk_cleanup_queue() Bart Van Assche

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190407110314.7145-1-shhuiw@foxmail.com \
    --to=shhuiw@foxmail.com \
    --cc=axboe@kernel.dk \
    --cc=linux-block@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.