<div><font face="Courier New" size="2">hello everyone</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font size="2"><font face="Courier New">I use yaffs2 on samsung nand flash(2k page 512M) now. I download latest mtd CVS from </font><a href="ftp://ftp.uk.linux.org/pub/people/dwmw2/mtd/cvs/"><font face="Courier New" size="3">
ftp://ftp.uk.linux.org/pub/people/dwmw2/mtd/cvs/</font></a></font><font face="Courier New" size="3"> </font><font size="2"></font></div>
<div><font face="Courier New" size="2">when I umount and remount, file disappear.I knew about the interface between yaffs2 and mtd have some problem.but in my yaffs2 source code this problem seems just fixed.yaffs2 put and read tags just in 2-38 field of oob.
</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New"><font size="2">I traced the code and found problem is here.</font><font size="2"> in nand_base.c. I found that if I use option NAND_ECC_NONE, the function nand_write_ecc would not read any oob data. However,in yaffs2 side, it suppose mtd->write_ecc will write data and tags.
</font></font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">code is here</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">$Id: nand_base.c,v 1.166 2006/03/13 06:09:08 vwool Exp $</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2"> static int nand_write_page (struct mtd_info *mtd, struct </font></div>
<div><font face="Courier New" size="2"> </font><font face="Courier New" size="2">nand_chip *this, int page,u_char *oob_buf, struct nand_oobinfo *oobsel, int cached)<br> {<br> ......</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2"> switch (eccmode) {<br> /* No ecc, write all */<br> case NAND_ECC_NONE:<br> printk (KERN_WARNING "Writing data without ECC to NAND-FLASH is not recommended\n");<br> this->write_buf(mtd, this->data_poi, mtd->oobblock);
<br> break;</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">nand_write_ecc calls nand_write_page, but if the option is NAND_ECC_NONE, it just simple writes 2048 byte data, break and return.</font></div>
<div><font face="Courier New" size="2">so yaffs2'tag is not written to oob.</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">I change nand_base.c to previous one whose nand_write_page will write oob, and yaffs2 works perfectly.</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">Does anyone have the same problem ? and Does this problem( nand_write_page do not write data to oob with option NAND_ECC_NONE) is a bug?</font></div>
<div><font face="Courier New" size="2"></font> </div>
<div><font face="Courier New" size="2">apologize for my poor english.</font></div>