public inbox for linux-block@vger.kernel.org
 help / color / mirror / Atom feed
From: Jean Delvare <jdelvare@suse.de>
To: linux-block@vger.kernel.org
Cc: Jens Axboe <axboe@kernel.dk>, Ming Lei <ming.lei@redhat.com>,
	Omar Sandoval <osandov@fb.com>, Hannes Reinecke <hare@suse.com>
Subject: [PATCH v2] block: Drop leftover references to RQF_SORTED
Date: Mon, 1 Mar 2021 17:23:25 +0100	[thread overview]
Message-ID: <20210301172325.1b2a16fe@endymion> (raw)

Commit a1ce35fa49852db60fc6e268038530be533c5b15 ("block: remove dead
elevator code") removed all users of RQF_SORTED. However it is still
defined, and there is one reference left to it (which in effect is
dead code). Clear it all up.

Signed-off-by: Jean Delvare <jdelvare@suse.de>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Ming Lei <ming.lei@redhat.com>
Cc: Omar Sandoval <osandov@fb.com>
Cc: Hannes Reinecke <hare@suse.com>
---
Changes since v1:
 * Remove parameter "has_sched" as it is no longer used. Spotted by
   Jens Axboe.

 block/blk-mq-debugfs.c |    1 -
 block/blk-mq-sched.c   |    6 +-----
 include/linux/blkdev.h |    2 --
 3 files changed, 1 insertion(+), 8 deletions(-)

--- linux-5.11.orig/block/blk-mq-sched.c	2021-03-01 12:05:12.991065582 +0100
+++ linux-5.11/block/blk-mq-sched.c	2021-03-01 17:07:12.914456908 +0100
@@ -391,7 +391,6 @@ void blk_mq_sched_request_inserted(struc
 EXPORT_SYMBOL_GPL(blk_mq_sched_request_inserted);
 
 static bool blk_mq_sched_bypass_insert(struct blk_mq_hw_ctx *hctx,
-				       bool has_sched,
 				       struct request *rq)
 {
 	/*
@@ -408,9 +407,6 @@ static bool blk_mq_sched_bypass_insert(s
 	if ((rq->rq_flags & RQF_FLUSH_SEQ) || blk_rq_is_passthrough(rq))
 		return true;
 
-	if (has_sched)
-		rq->rq_flags |= RQF_SORTED;
-
 	return false;
 }
 
@@ -424,7 +420,7 @@ void blk_mq_sched_insert_request(struct
 
 	WARN_ON(e && (rq->tag != BLK_MQ_NO_TAG));
 
-	if (blk_mq_sched_bypass_insert(hctx, !!e, rq)) {
+	if (blk_mq_sched_bypass_insert(hctx, rq)) {
 		/*
 		 * Firstly normal IO request is inserted to scheduler queue or
 		 * sw queue, meantime we add flush request to dispatch queue(
--- linux-5.11.orig/include/linux/blkdev.h	2021-03-01 12:05:12.991065582 +0100
+++ linux-5.11/include/linux/blkdev.h	2021-03-01 12:05:32.395297133 +0100
@@ -65,8 +65,6 @@ typedef void (rq_end_io_fn)(struct reque
  * request flags */
 typedef __u32 __bitwise req_flags_t;
 
-/* elevator knows about this request */
-#define RQF_SORTED		((__force req_flags_t)(1 << 0))
 /* drive already may have started this one */
 #define RQF_STARTED		((__force req_flags_t)(1 << 1))
 /* may not be passed by ioscheduler */
--- linux-5.11.orig/block/blk-mq-debugfs.c	2021-03-01 12:05:12.991065582 +0100
+++ linux-5.11/block/blk-mq-debugfs.c	2021-03-01 12:05:32.395297133 +0100
@@ -292,7 +292,6 @@ static const char *const cmd_flag_name[]
 
 #define RQF_NAME(name) [ilog2((__force u32)RQF_##name)] = #name
 static const char *const rqf_name[] = {
-	RQF_NAME(SORTED),
 	RQF_NAME(STARTED),
 	RQF_NAME(SOFTBARRIER),
 	RQF_NAME(FLUSH_SEQ),


-- 
Jean Delvare
SUSE L3 Support

             reply	other threads:[~2021-03-01 16:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-01 16:23 Jean Delvare [this message]
2021-03-01 17:16 ` [PATCH v2] block: Drop leftover references to RQF_SORTED Jens Axboe

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=20210301172325.1b2a16fe@endymion \
    --to=jdelvare@suse.de \
    --cc=axboe@kernel.dk \
    --cc=hare@suse.com \
    --cc=linux-block@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=osandov@fb.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox