Skip to content

Commit

Permalink
elevator: Remove argument from elevator_find_get
Browse files Browse the repository at this point in the history
Commit e4eb37c ("block: Remove elevator required features")
removed the usage of `struct request_queue` from elevator_find_get(),
but didn't removed the argument.

Remove the "struct request_queue *q" argument from elevator_find_get()
given it is useless.

Fixes: e4eb37c ("block: Remove elevator required features")
Signed-off-by: Breno Leitao <leitao@debian.org>
Link: https://lore.kernel.org/r/20241011155615.3361143-1-leitao@debian.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
leitao authored and axboe committed Oct 11, 2024
1 parent b4ff6e9 commit ee7ff15
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions block/elevator.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,7 @@ static struct elevator_type *__elevator_find(const char *name)
return NULL;
}

static struct elevator_type *elevator_find_get(struct request_queue *q,
const char *name)
static struct elevator_type *elevator_find_get(const char *name)
{
struct elevator_type *e;

Expand Down Expand Up @@ -569,7 +568,7 @@ static struct elevator_type *elevator_get_default(struct request_queue *q)
!blk_mq_is_shared_tags(q->tag_set->flags))
return NULL;

return elevator_find_get(q, "mq-deadline");
return elevator_find_get("mq-deadline");
}

/*
Expand Down Expand Up @@ -697,7 +696,7 @@ static int elevator_change(struct request_queue *q, const char *elevator_name)
if (q->elevator && elevator_match(q->elevator->type, elevator_name))
return 0;

e = elevator_find_get(q, elevator_name);
e = elevator_find_get(elevator_name);
if (!e)
return -EINVAL;
ret = elevator_switch(q, e);
Expand Down

0 comments on commit ee7ff15

Please sign in to comment.