All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] elevator.c: use ELV_NAME_MAX instead of magic number 16 for chosen_elevator
@ 2011-09-04 13:22 Wang Sheng-Hui
  2011-09-08  4:23 ` Wang Sheng-Hui
  0 siblings, 1 reply; 3+ messages in thread
From: Wang Sheng-Hui @ 2011-09-04 13:22 UTC (permalink / raw)
  To: Jens Axboe, linux-kernel

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@gmail.com>
---
 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


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-09-08 10:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-04 13:22 [PATCH] elevator.c: use ELV_NAME_MAX instead of magic number 16 for chosen_elevator Wang Sheng-Hui
2011-09-08  4:23 ` Wang Sheng-Hui
2011-09-08 10:32   ` Jens Axboe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.