mtd/drivers/mtd/nand nand_base.c,1.154,1.155
Vitaly Wool
vwool at ru.mvista.com
Mon Nov 14 01:45:29 EST 2005
- Previous message: mtd/fs/jffs2 debug.c, 1.13, 1.14 erase.c, 1.88, 1.89 gc.c, 1.157,
1.158 nodelist.c, 1.117, 1.118 nodelist.h, 1.143, 1.144 read.c,
1.43, 1.44 scan.c, 1.130, 1.131 summary.c, 1.7, 1.8 wbuf.c,
1.105, 1.106
- Next message: mtd/drivers/mtd/devices ms02-nv.c,1.10,1.11
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /home/cvs/mtd/drivers/mtd/nand
In directory phoenix.infradead.org:/tmp/cvs-serv7167/drivers/mtd/nand
Modified Files:
nand_base.c
Log Message:
Fixing the problem with HW ECC/layouts w/o SYNDROME
Even if SYNDROME is not set, it's more proper to let the device driver know
we're gonna read ECC otherwise it'll need to issue a positioning command
before the next read.
Index: nand_base.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/nand/nand_base.c,v
retrieving revision 1.154
retrieving revision 1.155
diff -u -r1.154 -r1.155
--- nand_base.c 7 Nov 2005 11:14:30 -0000 1.154
+++ nand_base.c 14 Nov 2005 06:45:25 -0000 1.155
@@ -937,7 +937,7 @@
datidx += this->layout[j].length;
break;
case ITEM_TYPE_ECC:
- this->enable_hwecc(mtd, NAND_ECC_WRITESYN); /* XXX: only for syndrome? */
+ this->enable_hwecc(mtd, NAND_ECC_WRITESYN);
this->calculate_ecc(mtd, &this->data_poi[last_datidx], &ecc_code[i]);
for (; i < last_i + this->layout[j].length; i++, eccidx++)
oob_buf[oob_config[eccidx]] = ecc_code[i];
@@ -1282,11 +1282,10 @@
case ITEM_TYPE_ECC:
DEBUG (MTD_DEBUG_LEVEL3, "%s: reading %d ecc bytes\n", __FUNCTION__, this->layout[j].length);
- /* HW ecc with syndrome calculation must read the
- * syndrome from flash immidiately after the data */
+ /* let the particular driver decide whether to read ECC */
+ this->enable_hwecc(mtd, NAND_ECC_READSYN);
+ this->read_buf(mtd, &oob_data[i], this->layout[j].length);
if (!compareecc) {
- this->enable_hwecc(mtd, NAND_ECC_READSYN);
- this->read_buf(mtd, &oob_data[i], this->layout[j].length);
/* We calc error correction directly, it checks the hw
* generator for an error, reads back the syndrome and
- Previous message: mtd/fs/jffs2 debug.c, 1.13, 1.14 erase.c, 1.88, 1.89 gc.c, 1.157,
1.158 nodelist.c, 1.117, 1.118 nodelist.h, 1.143, 1.144 read.c,
1.43, 1.44 scan.c, 1.130, 1.131 summary.c, 1.7, 1.8 wbuf.c,
1.105, 1.106
- Next message: mtd/drivers/mtd/devices ms02-nv.c,1.10,1.11
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the linux-mtd-cvs
mailing list