summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorChuck Ebbert <76306.1226@compuserve.com>2006-01-16 22:14:55 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-01-16 23:15:32 -0800
commit4c2645830e29c082217662e7486572e9637e9f1d (patch)
tree655bc2d3825e7a1b1ee1f60a40e98bf165577b5c /block
parent5aeebe01cb2ba1bca4cd9b8a6e77386bd7499dc2 (diff)
[PATCH] elevator=as back-compatibility
As of 2.6.15 you need to use "anticipatory" instead of "as". Fix that up so that `elevator=as' still works. Signed-off-by: Chuck Ebbert <76306.1226@compuserve.com> Cc: Nick Piggin <nickpiggin@yahoo.com.au> Cc: Jens Axboe <axboe@suse.de> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'block')
-rw-r--r--block/elevator.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/block/elevator.c b/block/elevator.c
index 1d0759178e4..e8025b2ec54 100644
--- a/block/elevator.c
+++ b/block/elevator.c
@@ -149,6 +149,13 @@ static void elevator_setup_default(void)
if (!chosen_elevator[0])
strcpy(chosen_elevator, CONFIG_DEFAULT_IOSCHED);
+ /*
+ * Be backwards-compatible with previous kernels, so users
+ * won't get the wrong elevator.
+ */
+ if (!strcmp(chosen_elevator, "as"))
+ strcpy(chosen_elevator, "anticipatory");
+
/*
* If the given scheduler is not available, fall back to no-op.
*/