diff -u -r1.121 nand_base.c --- nand_base.c 6 Oct 2004 19:53:11 -0000 1.121 +++ nand_base.c 8 Oct 2004 10:34:39 -0000 @@ -310,11 +310,17 @@ { int i; struct nand_chip *this = mtd->priv; + u_char tmp; - for (i=0; iIO_ADDR_R)) + for (i=0; iIO_ADDR_R); + if (buf[i] != tmp) { + DEBUG (MTD_DEBUG_LEVEL0, + "Verify failed: 0x%02x instead of 0x%02x at offset %d\n", + tmp, buf[i], i); return -EFAULT; - + } + } return 0; } @@ -955,7 +961,7 @@ */ if (oobmode) { if (this->verify_buf(mtd, &oob_buf[oobofs], mtd->oobsize - hweccbytes * eccsteps)) { - DEBUG (MTD_DEBUG_LEVEL0, "%s: " "Failed write verify, page 0x%08x ", __FUNCTION__, page); + DEBUG (MTD_DEBUG_LEVEL0, "%s: " "Failed write verify oob, page 0x%08x ", __FUNCTION__, page); goto out; } } else {