MT7621 NAND OOB misdetect

Peter Naulls peter at chocky.org
Sat Feb 11 04:41:24 PST 2023


On 2/10/23 22:41, Chuanhong Guo wrote:
> Hi!
> 
16.163318] 8 fixed-partitions partitions found on MTD device mt7621-nand
> 
>  From the datasheet here:
> https://www.mxic.com.tw/Lists/Datasheet/Attachments/8858/MX30LF1G28AD,%203V,%201Gb,%20v1.3.pdf
> The MX30LF1G28AD actually have 2K+128 flash layout, so it's the old driver
> which is incorrectly detecting OOB size.
> 
>> Suffice to that accessing the device (nanddump) does not go well.
> 
> Could you describe what exactly goes wrong?
> 

Thanks for your reply. Sorry, yes, I should have included that output.

In particular, this fails:

[   28.070690] mt76x2e 0000:02:00.0: reading EEPROM from mtd factory failed: -77
[   28.717408] mt76x2e 0000:02:00.0: Invalid MAC address, using random address 
02:73:0b:95:75:d9

I have verified that the correct MAC address does in fact exist in flash at the
same location as it did on the NOR under the legacy kernel.

And then also at the end of boot (mtd6 is rootfs):

[   33.335299] blk_update_request: I/O error, dev mtdblock6, sector 0 op 
0x0:(READ) flags 0x80700 phys_seg 4 prio class 0
[   33.359479] blk_update_request: I/O error, dev mtdblock6, sector 8 op 
0x0:(READ) flags 0x80700 phys_seg 3 prio class 0
[   33.383345] blk_update_request: I/O error, dev mtdblock6, sector 16 op 
0x0:(READ) flags 0x80700 phys_seg 2 prio class 0
[   33.407643] blk_update_request: I/O error, dev mtdblock6, sector 24 op 
0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
[   33.431898] blk_update_request: I/O error, dev mtdblock6, sector 0 op 
0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[   33.452624] Buffer I/O error on dev mtdblock6, logical block 0, async page read
[   33.476059] blk_update_request: I/O error, dev mtdblock6, sector 36736 op 
0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
[   33.501107] blk_update_request: I/O error, dev mtdblock6, sector 36736 op 
0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[   33.522557] Buffer I/O error on dev mtdblock6, logical block 4592, async page 
read

And then for example:


# nanddump -a /dev/mtd2
ECC failed: 8
ECC corrected: 0
Number of bad blocks: 0
Number of bbt blocks: 0
Block size 131072, page size 2048, OOB size 128
Dumping data starting at 0x00000000 and ending at 0x00040000...
libmtd: error!: MEMGETBADBLOCK ioctl failed for eraseblock 0 (mtd2)
         error 77 (Bad message)
nanddump: error!: libmtd: mtd_is_bad

I haven't been able to find anything on what this error means in practice.








More information about the openwrt-devel mailing list