Uncorrectable ECC error

I see following error when device boots. Does that mean NAND flash has become corrupt? Can this problem be corrected or is it a hardware level problem?

[    0.585274] mt7621-nand 1e003000.nand: Using programmed access timing: 31c07388
[    0.592814] nand: device found, Manufacturer ID: 0xef, Chip ID: 0xf1
[    0.599148] nand: Winbond W29N01HV
[    0.602545] nand: 128 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[    0.610098] mt7621-nand 1e003000.nand: ECC strength adjusted to 4 bits
[    0.616637] mt7621-nand 1e003000.nand: Using programmed access timing: 21005134
[    0.623931] mt7621-nand 1e003000.nand: Using programmed access timing: 21005134
[    0.631216] Scanning device for bad blocks
[    0.640599] mt7621-nand 1e003000.nand: Uncorrectable ECC error at page 512.0
[    0.647805] mt7621-nand 1e003000.nand: Uncorrectable ECC error at page 512.1
[    0.654992] mt7621-nand 1e003000.nand: Uncorrectable ECC error at page 512.2
[    0.662184] mt7621-nand 1e003000.nand: Uncorrectable ECC error at page 512.3

Yes, that nand blocks are corrupted.
But this means not that the nand chip has to be replaced.
Raw flash devices like NAND requires handling of bad blocks at the driver level instead of in the firmware, like on SSDs.
Bad blocks in flash chips are a normal thing.

This info only does inform you that there are bad blocks that are handled by the nand driver.
You don't have to do anything to correct the bad blocks.
It's a hardware level problem that is handled in software by the nand driver.

2 Likes

I also have the same device and flashed openers and I get the exact same error. If the NAND is bad how can both devices have the exact same bad NAND. Can this be ignored ?

The error is due to s_env. Just format that and error would go away. Apparently, the problem happens when device fails to boot for 3 times and boots from alt partition.

How do I format the partition in openwrt safely ?

Run following commands from shell:

mtd unlock s_env
mtd erase s_env
1 Like

If your problem is solved, please consider marking this topic as [Solved]. See How to mark a topic as [Solved] for a short how-to.