* [PATCH] UML - Fix fencepost errors in printks
@ 2004-09-23 2:24 Jeff Dike
0 siblings, 0 replies; only message in thread
From: Jeff Dike @ 2004-09-23 2:24 UTC (permalink / raw)
To: akpm; +Cc: linux-kernel, blaisorblade_spam
Simple corrections to some error messages, which list wrong limits for UBD
devices and such.
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade_spam@yahoo.it>
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Index: linux-2.6.9-rc2-mm1-orig/arch/um/drivers/line.c
===================================================================
--- linux-2.6.9-rc2-mm1-orig.orig/arch/um/drivers/line.c 2004-09-22 19:51:02.000000000 -0400
+++ linux-2.6.9-rc2-mm1-orig/arch/um/drivers/line.c 2004-09-22 20:39:58.000000000 -0400
@@ -332,7 +332,7 @@
init++;
if((n >= 0) && (n >= num)){
printk("line_setup - %d out of range ((0 ... %d) allowed)\n",
- n, num);
+ n, num - 1);
return(0);
}
else if(n >= 0){
Index: linux-2.6.9-rc2-mm1-orig/arch/um/drivers/ubd_kern.c
===================================================================
--- linux-2.6.9-rc2-mm1-orig.orig/arch/um/drivers/ubd_kern.c 2004-09-22 19:51:02.000000000 -0400
+++ linux-2.6.9-rc2-mm1-orig/arch/um/drivers/ubd_kern.c 2004-09-22 20:39:58.000000000 -0400
@@ -299,7 +299,7 @@
}
if(n >= MAX_DEV){
printk(KERN_ERR "ubd_setup : index %d out of range "
- "(%d devices)\n", n, MAX_DEV);
+ "(%d devices, from 0 to %d)\n", n, MAX_DEV, MAX_DEV - 1);
return(1);
}
More recent patches modify files in message-off-by-one.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2004-09-23 1:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-09-23 2:24 [PATCH] UML - Fix fencepost errors in printks Jeff Dike
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®