From ddb7253254fee6922764043101f8b28b6a00595d Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Thu, 31 May 2018 19:11:38 +0200 Subject: block: remove the always unused name argument to elevator_init Reported-by: Damien Le Moal Signed-off-by: Christoph Hellwig Reviewed-by: Damien Le Moal Tested-by: Damien Le Moal Signed-off-by: Jens Axboe --- block/elevator.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'block/elevator.c') diff --git a/block/elevator.c b/block/elevator.c index a7baa4687b28d..9276540af2a17 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -199,7 +199,7 @@ static void elevator_release(struct kobject *kobj) kfree(e); } -int elevator_init(struct request_queue *q, char *name) +int elevator_init(struct request_queue *q) { struct elevator_type *e = NULL; int err; @@ -213,19 +213,13 @@ int elevator_init(struct request_queue *q, char *name) if (unlikely(q->elevator)) return 0; - if (name) { - e = elevator_get(q, name, true); - if (!e) - return -EINVAL; - } - /* * Use the default elevator specified by config boot param for * non-mq devices, or by config option. Don't try to load modules * as we could be running off async and request_module() isn't * allowed from async. */ - if (!e && !q->mq_ops && *chosen_elevator) { + if (!q->mq_ops && *chosen_elevator) { e = elevator_get(q, chosen_elevator, false); if (!e) printk(KERN_ERR "I/O scheduler %s not found\n", -- cgit v1.2.3