可以确定启动配置肯定是正确的,就是NandFlash启动的。我手上有两份NandFlash的驱动,唯一区别是ECC写在Spare Page里的位置不一样,把同一份UBL固件烧写在同一个机器的NandFlash的第一块,但是就是有一个正常启动,另一个不能启动,不能启动的机器PC地址还在ROM里面,也就是说,ROM没有找到UBL固件了吧!难道ROM启动代码在读NandFlash是也有做ECC的?是这样子的吗?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
可以确定启动配置肯定是正确的,就是NandFlash启动的。我手上有两份NandFlash的驱动,唯一区别是ECC写在Spare Page里的位置不一样,把同一份UBL固件烧写在同一个机器的NandFlash的第一块,但是就是有一个正常启动,另一个不能启动,不能启动的机器PC地址还在ROM里面,也就是说,ROM没有找到UBL固件了吧!难道ROM启动代码在读NandFlash是也有做ECC的?是这样子的吗?
参考bootloader文档:sprab41e:
6.4 NAND Flash Boot
To boot from NAND Flash, the AIS should be written to NAND block 1 (NAND block 0 is not used by
default) in a sequential manner, skipping (and marking) any bad blocks. The bootloader detects a bad
block by examining the spare bytes in the first and second pages of the current block. For NAND devices
that comply with the ONFI standard, the first and last pages are used instead. Figure 21 illustrates the
structure of a NAND data page. Each page includes N segments of spare bytes, where N is the number of
data bytes per page divided by 512. Each segment of spare bytes contains 6 test bytes and 10 ECC
bytes. For those pages that are checked during bad block detection, all the test bytes in each segment
must equal FFh; any other value indicates that the page (and its entire block) is bad and should not be
used.