summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2017-02-14 08:17:51 -0700
committerJens Axboe <axboe@fb.com>2017-02-14 08:17:51 -0700
commit175e1638ed40cd18660f848842dfcaf74cfc8f2c (patch)
treed1e17f49697956d6151b23fd61073d0a2cb226f8 /block
parent3370e831809a7e02e3179dd097566e8a71a87a29 (diff)
parentd1a987f35ebf859a771ac530e95a89933b6fcce8 (diff)
Merge branch 'for-4.11/block' into for-next
Diffstat (limited to 'block')
-rw-r--r--block/elevator.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/block/elevator.c b/block/elevator.c
index 27ff1ed5a6fa..699d10f71a2c 100644
--- a/block/elevator.c
+++ b/block/elevator.c
@@ -207,11 +207,12 @@ int elevator_init(struct request_queue *q, char *name)
}
/*
- * Use the default elevator specified by config boot param or
- * config option. Don't try to load modules as we could be running
- * off async and request_module() isn't allowed from async.
+ * 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 && *chosen_elevator) {
+ if (!e && !q->mq_ops && *chosen_elevator) {
e = elevator_get(chosen_elevator, false);
if (!e)
printk(KERN_ERR "I/O scheduler %s not found\n",