Some questions on bit-flips and JFFS2
muehlfelder at enertex.de
Tue May 4 10:59:26 EDT 2010
Am Tuesday 04 May 2010 11:28:54 schrieb Norbert van Bolhuis:
> Thorsten Mühlfelder wrote:
> > Hi there,
> > I'm experiencing some problems with bit-flips on devices using NAND and
> > JFFS2: NAND device: Manufacturer ID: 0x2c, Chip ID: 0xdc (Micron NAND
> > 512MiB 3,3V 8-bit)
> > Creating 2 MTD partitions on "NAND 512MiB 3,3V 8-bit":
> > 0x00000000-0x00a00000 : "Bootloader Area"
> > 0x00a00000-0x20000000 : "User Area"
> > In rare cases 1 or 2 bits in the bootloader area (kernel) flip, so that
> > the system won't boot anymore (kernel checksum error).
> > As the bootloader image is not mounted at all I wonder if this may be
> > caused by these read disturbs I've heard of.
> > PS: I could not reproduce the bit-flip problem. It just happens in rare
> > cases. Furthermore some of my devices are using Samsung NAND instead of
> > the Micron NAND and did not show any problems yet. So perhaps my problem
> > are just some bad NAND chip? But still I have to find a solution for the
> > problem.
> Maybe, as said check/ask your hardware supplier.
> Maybe "refreshing" the block helps (that is saving the data, erasing the
> block(s) and reprogramming all data). You could try this.
I've already thought about something like this:
1. After first succesful bootup dump a mtd0 image and calculate a md5sum of
nanddump -o -b -f mtd0.img /dev/mtd0
2. Before each shutdown dump the image again and check if the md5sum has
3. If it has changed write the initial dump back:
nandwrite -p /dev/mtd0 mtd0.img
Would this be the right method?
> The best solution is of course UBIFS. UBI/UBIFS will handle bad blocks and
> read/write disturbs. Include your kernel partition into the (big) flash
> filesystem partition and start using UBIFS (i.s.o. JFFS2).
Is there any How-To for U-Boot?
More information about the linux-mtd