|
@@ -1055,6 +1055,10 @@ static int __elevator_change(struct request_queue *q, const char *name)
|
|
char elevator_name[ELV_NAME_MAX];
|
|
char elevator_name[ELV_NAME_MAX];
|
|
struct elevator_type *e;
|
|
struct elevator_type *e;
|
|
|
|
|
|
|
|
+ /* Make sure queue is not in the middle of being removed */
|
|
|
|
+ if (!test_bit(QUEUE_FLAG_REGISTERED, &q->queue_flags))
|
|
|
|
+ return -ENOENT;
|
|
|
|
+
|
|
/*
|
|
/*
|
|
* Special case for mq, turn off scheduling
|
|
* Special case for mq, turn off scheduling
|
|
*/
|
|
*/
|