mtd/drivers/mtd/chips cfi_cmdset_0002.c,1.82,1.83 jedec_probe.c,1.31,1.32

Thayne Harbaugh tharbaugh at lnxi.com
Wed Oct 1 13:40:08 EDT 2003


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

Modified Files:
	cfi_cmdset_0002.c jedec_probe.c 
Log Message:
- Must multiply by number of interleaved chips to test fit

- Might as well have an array of four chars

- Add my name in so that people can track down the perpetrator

Index: cfi_cmdset_0002.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/chips/cfi_cmdset_0002.c,v
retrieving revision 1.82
retrieving revision 1.83
diff -u -r1.82 -r1.83
--- cfi_cmdset_0002.c	30 Sep 2003 14:08:00 -0000	1.82
+++ cfi_cmdset_0002.c	1 Oct 2003 17:40:05 -0000	1.83
@@ -8,6 +8,8 @@
  *
  * 4_by_16 work by Carolyn J. Smith
  *
+ * Occasionally maintained by Thayne Harbaugh tharbaugh at lnxi dot com
+ *
  * This code is GPL
  *
  * $Id$

Index: jedec_probe.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/chips/jedec_probe.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- jedec_probe.c	29 Sep 2003 23:10:11 -0000	1.31
+++ jedec_probe.c	1 Oct 2003 17:40:05 -0000	1.32
@@ -4,6 +4,8 @@
    $Id$
    See JEDEC (http://www.jedec.org/) standard JESD21C (section 3.5)
    for the standard this probe goes back to.
+
+   Occasionally maintained by Thayne Harbaugh tharbaugh at lnxi dot com
 */
 
 #include <linux/config.h>
@@ -213,7 +215,7 @@
 	const int InterfaceDesc;
 	const int NumEraseRegions;
 	const int CmdSet;
-	const __u8 uaddr[3];		/* unlock addrs for 8, 16, 32 modes */
+	const __u8 uaddr[4];		/* unlock addrs for 8, 16, 32, 64 */
 	const ulong regions[4];
 };
 
@@ -1521,7 +1523,7 @@
 	DEBUG( MTD_DEBUG_LEVEL3,
 	       "MTD %s(): Check fit 0x%.8x + 0x%.8x = 0x%.8x\n",
 	       __func__, base, 1 << finfo->DevSize, base + (1 << finfo->DevSize) );
-	if ( base + ( 1 << finfo->DevSize ) > map->size ) {
+	if ( base + cfi->interleave * ( 1 << finfo->DevSize ) > map->size ) {
 		DEBUG( MTD_DEBUG_LEVEL3,
 		       "MTD %s(): 0x%.4x 0x%.4x %dKiB doesn't fit\n",
 		       __func__, finfo->mfr_id, finfo->dev_id,




More information about the linux-mtd-cvs mailing list