mtd/drivers/mtd/nand au1550nd.c,1.14,1.15

David Woodhouse dwmw2 at infradead.org
Wed Mar 29 03:31:15 EST 2006


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

Modified Files:
	au1550nd.c 
Log Message:
From: Tobias Klauser <tklauser at nuerscht.ch>

Use ARRAY_SIZE macro instead of sizeof(x)/sizeof(x[0]) and remove
duplicates of the macro.

Signed-off-by: Tobias Klauser <tklauser at nuerscht.ch>
Cc: Thomas Gleixner <tglx at linutronix.de>
Signed-off-by: David Woodhouse <dwmw2 at infradead.org>
Signed-off-by: Andrew Morton <akpm at osdl.org>


Index: au1550nd.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/nand/au1550nd.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- au1550nd.c	13 Nov 2005 09:52:07 -0000	1.14
+++ au1550nd.c	29 Mar 2006 08:31:12 -0000	1.15
@@ -56,8 +56,6 @@
  		.size 	=    MTDPART_SIZ_FULL
 	}
 };
-#define NB_OF(x)  (sizeof(x)/sizeof(x[0]))
-
 
 /**
  * au_read_byte -  read one byte from the chip
@@ -597,7 +595,7 @@
 	}
 
 	/* Register the partitions */
-	add_mtd_partitions(au1550_mtd, partition_info, NB_OF(partition_info));
+	add_mtd_partitions(au1550_mtd, partition_info, ARRAY_SIZE(partition_info));
 
 	return 0;
 





More information about the linux-mtd-cvs mailing list