From: Hongfu Li <hongfu.li@linux.dev>
To: axboe@kernel.dk
Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
hongfu.li@linux.dev, Hongfu Li <lihongfu@kylinos.cn>
Subject: [PATCH] block/mq-deadline: Drop unused dd parameters
Date: Tue, 11 Aug 2026 14:54:01 +0800 [thread overview]
Message-ID: <20260811065401.87147-1-hongfu.li@linux.dev> (raw)
From: Hongfu Li <lihongfu@kylinos.cn>
Commit c807ab520fc3 ("block/mq-deadline: Add I/O priority support")
left the dd parameter unused in deadline_move_request().
Commit fde02699c242 ("block: mq-deadline: Remove support for zone
write locking") left dd unused in deadline_fifo_request() and
deadline_next_request().
Remove these unused function parameters.
Signed-off-by: Hongfu Li <lihongfu@kylinos.cn>
---
block/mq-deadline.c | 17 ++++++++---------
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/block/mq-deadline.c b/block/mq-deadline.c
index 824bfc17b2c6..314cd1fd1f39 100644
--- a/block/mq-deadline.c
+++ b/block/mq-deadline.c
@@ -234,8 +234,7 @@ static void dd_merged_requests(struct request_queue *q, struct request *req,
* move an entry to dispatch queue
*/
static void
-deadline_move_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
- struct request *rq)
+deadline_move_request(struct dd_per_prio *per_prio, struct request *rq)
{
/*
* take it off the sort and fifo list
@@ -270,7 +269,7 @@ static inline bool deadline_check_fifo(struct dd_per_prio *per_prio,
* dispatch using arrival ordered lists.
*/
static struct request *
-deadline_fifo_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
+deadline_fifo_request(struct dd_per_prio *per_prio,
enum dd_data_dir data_dir)
{
if (list_empty(&per_prio->fifo_list[data_dir]))
@@ -284,7 +283,7 @@ deadline_fifo_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
* dispatch using sector position sorted lists.
*/
static struct request *
-deadline_next_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
+deadline_next_request(struct dd_per_prio *per_prio,
enum dd_data_dir data_dir)
{
return deadline_from_pos(per_prio, data_dir,
@@ -334,7 +333,7 @@ static struct request *__dd_dispatch_request(struct deadline_data *dd,
/*
* batches are currently reads XOR writes
*/
- rq = deadline_next_request(dd, per_prio, dd->last_dir);
+ rq = deadline_next_request(per_prio, dd->last_dir);
if (rq && dd->batching < dd->fifo_batch) {
/* we have a next request and are still entitled to batch */
data_dir = rq_data_dir(rq);
@@ -349,7 +348,7 @@ static struct request *__dd_dispatch_request(struct deadline_data *dd,
if (!list_empty(&per_prio->fifo_list[DD_READ])) {
BUG_ON(RB_EMPTY_ROOT(&per_prio->sort_list[DD_READ]));
- if (deadline_fifo_request(dd, per_prio, DD_WRITE) &&
+ if (deadline_fifo_request(per_prio, DD_WRITE) &&
(dd->starved++ >= dd->writes_starved))
goto dispatch_writes;
@@ -379,14 +378,14 @@ static struct request *__dd_dispatch_request(struct deadline_data *dd,
/*
* we are not running a batch, find best request for selected data_dir
*/
- next_rq = deadline_next_request(dd, per_prio, data_dir);
+ next_rq = deadline_next_request(per_prio, data_dir);
if (deadline_check_fifo(per_prio, data_dir) || !next_rq) {
/*
* A deadline has expired, the last request was in the other
* direction, or we have run out of higher-sectored requests.
* Start again from the request with the earliest expiry time.
*/
- rq = deadline_fifo_request(dd, per_prio, data_dir);
+ rq = deadline_fifo_request(per_prio, data_dir);
} else {
/*
* The last req was the same dir and we have a next request in
@@ -409,7 +408,7 @@ static struct request *__dd_dispatch_request(struct deadline_data *dd,
* rq is the selected appropriate request.
*/
dd->batching++;
- deadline_move_request(dd, per_prio, rq);
+ deadline_move_request(per_prio, rq);
return dd_start_request(dd, data_dir, rq);
}
--
2.54.0
reply other threads:[~2026-08-11 6:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20260811065401.87147-1-hongfu.li@linux.dev \
--to=hongfu.li@linux.dev \
--cc=axboe@kernel.dk \
--cc=lihongfu@kylinos.cn \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox