Some questions on bit-flips and JFFS2

Thorsten Mühlfelder muehlfelder at enertex.de
Wed May 19 03:45:13 EDT 2010


Am Wednesday 12 May 2010 14:22:19 schrieb Ricard Wanderlof:
> > - Or write some tool, that can distinguish between real bad blocks and
> > the Sam-ba 2.5 created bad blocks, unmark the false bad blocks. But
> > perhaps this is not possible at all.
>
> It depends on how exactly Sam-ba 2.5 overwrites the existing bad block
> markers.

As you can see here the Sam-Ba 2.5 tool writes some ECC code to the first 4 
bytes of each erase block's OOB while in the first byte the bad block 
information usually is stored. Therefore it is impossible to restore factory 
set bad blocks. IMHO this is a mature bug in Atmel's Sam-Ba tool, but it is 
fixed in newer versions.
I'm quite sure this behaviour is the source of my problem. Probably factory 
set bad blocks have been overwritten by Sam-Ba and I guess in these blocks 
occur the bit flips:

nand dump 0x100000
Page 00100000 dump:
...
OOB:
	b1 20 46 df ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 0x100800
Page 00100800 dump:
...
OOB:
	71 31 86 ce ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 101800
Page 00101800 dump:
...
OOB:
	16 4b 16 4b ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 102000
Page 00102000 dump:
...
OOB:
	06 47 f1 b8 ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 102800
Page 00102800 dump:
...
OOB:
	24 5c d3 a3 ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 103000
Page 00103000 dump:
...
OOB:
	c3 37 c3 37 ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
U-Boot> nand dump 103800
Page 00103800 dump:
...
OOB:
	81 0c 81 0c ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff
	ff ff ff ff ff ff ff ff



More information about the linux-mtd mailing list