mtd/fs/jffs2 wbuf.c,1.71,1.72
gleixner at infradead.org
gleixner at infradead.org
Sat Sep 11 15:22:46 EDT 2004
Update of /home/cvs/mtd/fs/jffs2
In directory phoenix.infradead.org:/tmp/cvs-serv4341
Modified Files:
wbuf.c
Log Message:
fix the check for bad ECC on read as it was changed in nand some time ago
Index: wbuf.c
===================================================================
RCS file: /home/cvs/mtd/fs/jffs2/wbuf.c,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -r1.71 -r1.72
--- wbuf.c 23 Aug 2004 16:25:08 -0000 1.71
+++ wbuf.c 11 Sep 2004 19:22:43 -0000 1.72
@@ -225,7 +225,7 @@
/* Do the read... */
ret = c->mtd->read_ecc(c->mtd, start, c->wbuf_ofs - start, &retlen, buf, NULL, c->oobinfo);
- if (ret == -EIO && retlen == c->wbuf_ofs - start) {
+ if (ret == -EBADMSG && retlen == c->wbuf_ofs - start) {
/* ECC recovered */
ret = 0;
}
@@ -791,7 +791,7 @@
if (!jffs2_can_mark_obsolete(c)) {
ret = c->mtd->read_ecc(c->mtd, ofs, len, retlen, buf, NULL, c->oobinfo);
- if ( (ret == -EIO) && (*retlen == len) ) {
+ if ( (ret == -EBADMSG) && (*retlen == len) ) {
printk(KERN_WARNING "mtd->read(0x%zx bytes from 0x%llx) returned ECC error\n",
len, ofs);
/*
More information about the linux-mtd-cvs
mailing list