mtd/drivers/mtd/devices block2mtd.c,1.27,1.28

gleixner at infradead.org gleixner at infradead.org
Sat Mar 19 17:40:47 EST 2005


Update of /home/cvs/mtd/drivers/mtd/devices
In directory phoenix.infradead.org:/tmp/cvs-serv5788

Modified Files:
	block2mtd.c 
Log Message:
MTD: block2mtd. Fix incompatible pointer type



Index: block2mtd.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/devices/block2mtd.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -r1.27 -r1.28
--- block2mtd.c	18 Mar 2005 01:37:31 -0000	1.27
+++ block2mtd.c	19 Mar 2005 22:40:44 -0000	1.28
@@ -368,16 +368,16 @@
 }
 
 
-static int parse_num32(u32 *num32, const char *token)
+static int parse_num(size_t *num, const char *token)
 {
 	char *endp;
-	unsigned long n;
+	size_t n;
 
-	n = ustrtoul(token, &endp, 0);
+	n = (size_t) ustrtoul(token, &endp, 0);
 	if (*endp)
 		return -EINVAL;
 
-	*num32 = n;
+	*num = n;
 	return 0;
 }
 
@@ -447,7 +447,7 @@
 		return 0;
 
 	if (token[1]) {
-		ret = parse_num32(&erase_size, token[1]);
+		ret = parse_num(&erase_size, token[1]);
 		if (ret)
 			parse_err("illegal erase size");
 	}





More information about the linux-mtd-cvs mailing list