Whamcloud - gitweb
LU-11913 utils: allow "mq-deadline" as scheduler 63/34163/2
authorAndreas Dilger <adilger@whamcloud.com>
Fri, 1 Feb 2019 20:10:40 +0000 (13:10 -0700)
committerOleg Drokin <green@whamcloud.com>
Wed, 27 Feb 2019 02:02:29 +0000 (02:02 +0000)
Allow the "mq-deadline" scheduler for multi-queue block devices, in
addition to just "noop" and "deadline".  Explicitly add "deadline"
as a valid option, in case the default scheduler is changed.

Test-Parameters: trivial
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: I2cb0878188aea43f88c503ea70a699be083ebbe5
Reviewed-on: https://review.whamcloud.com/34163
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/utils/libmount_utils_ldiskfs.c

index b40b7da..6807305 100644 (file)
@@ -1209,7 +1209,9 @@ static int tune_block_dev_scheduler(const char *sys_path, const char *new_sched)
        *e = '\0';
 
        if (strcmp(old_sched, "noop") == 0 ||
-           strcmp(old_sched, new_sched) == 0)
+           strcmp(old_sched, "deadline") == 0 ||
+           strcmp(old_sched, "mq-deadline") == 0 ||
+           strstr(old_sched, new_sched) == 0)
                return 0;
 
        rc = write_file(path, new_sched);