bit flip

David Woodhouse dwmw2 at infradead.org
Wed Oct 10 00:48:17 EDT 2007


On Wed, 2007-10-03 at 14:32 -0500, catboat at texas.net wrote:
> A NAND card flipped a bit and caused a data CRC problem in a data node. 
> When I cat the file, this region is zeroes. cat exits with rc 0.

On NAND you should have ECC to prevent this failure mode.

> I can simulate this. I made a jffs2 file system using mkfs.jffs2. 
> In a file with multiple data nodes, I manually flip a bit in one of them.
> At mount time, I see a printk about it.  cat exits with 0 and the file has a 
> chunk of zeroes in it.
> 
> Seems incorrect to me.  I expected jffs2 to return EIO somewhere.
> 
> Does it seem incorrect to you? 

We could probably manage that -- there should never be any _holes_ in
the file. It's not a panacea though, because sometimes if the latest
node is corrupted you might just see 'old' dirty data from an earlier
version, rather than a hole.

-- 
dwmw2




More information about the linux-mtd mailing list