[PATCH] elevator.c: use ELV_NAME_MAX instead of magic number 16 forchosen_elevator

From: Wang Sheng-Hui
Date: Sun Sep 04 2011 - 09:24:39 EST


We have ELV_NAME_MAX defined to 16, and hence we should use it
instead of the magic nubmer 16 for elevator's name string.

The patch is against 3.1-rc3.

Signed-off-by: Wang Sheng-Hui <shhuiw@xxxxxxxxx>
---
block/elevator.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/block/elevator.c b/block/elevator.c
index a3b64bc..cb332cb 100644
--- a/block/elevator.c
+++ b/block/elevator.c
@@ -182,7 +182,7 @@ static void elevator_attach(struct request_queue *q, struct elevator_queue *eq,
eq->elevator_data = data;
}

-static char chosen_elevator[16];
+static char chosen_elevator[ELV_NAME_MAX];

static int __init elevator_setup(char *str)
{
--
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/