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.
Hi,
I am attempting to upgrade EZSDK versions from 5.03 to 5.05. We have been using 5.03 for a long time, successfully, but I need to upgrade to EZSDK 5.05 for a variety of reasons - one of them being able to use BCH8 for u-boot & kernel.
I have finished porting over the few patches that we need to make to get the EZSDK to work with our board (this is not the EVM), but now I am having trouble with the NAND. I have flashed everything as BCH8, and in fact, I can boot all the way and linux is running, however I keep getting prints like these:
<<
Read of newly-erased block at 0x00740000 failed: -74. Putting on bad_list
>>
The system is "usable", but more and more of these pop up, and when I reboot to u-boot and run the "nand bad" command, I can see that more and more blocks are being marked bad.
This is the exact same unit that I have been using daily for many months, and it has never had even a single bad block before...now the list is many dozens.
Any ideas, places to start?
Thanks,
Joel
Looking in to this further, I notice that the following note is written in the PSP 04.04.00.01 Release Notes:
<<
UBIFS file system support has been enabled by default in the kernel. Since 8-bit BCH ECC scheme is using [2-57] bytes of the 64 byte OOB area in NAND, accommodating metadata for JFFS2 file system can not be supported with 8-bit ECC scheme. Hence, usage of UBIFS file system is recommended.
>>
I am still using JFFS2. Seems like this is a likely cause of the errors I'm seeing. Can anyone confirm this? Is there anyway to continue to use JFFS2 with BCH8 ECC, or must I switch to UBIFS? Can anyone point me to the conflict in the OOB layout?
Thanks,
Joel
Joel,
Here is more info from the developers:
"
Q:
Is there really no support for BCH8 with JFFS2, only with UBIFS? In the release notes there is this warning (http://processors.wiki.ti.com/index.php/TI81XX_PSP_04.04.00.01_Release_Notes):
"UBIFS file system support has been enabled by default in the kernel. Since 8-bit BCH ECC scheme is using [2-57] bytes of the 64 byte OOB area in NAND, accommodating metadata for JFFS2 file system can not be supported with 8-bit ECC scheme. Hence, usage of UBIFS file system is recommended."
A:
- JFFS2 cannot be used along with BCH8 ECC, only on 2K/64B NAND devices.
http://processors.wiki.ti.com/index.php/AM335x_JFFS2_Support_Guide#Reasons_for_disabling_JFFS2_support
http://processors.wiki.ti.com/index.php/TI81XX_PSP_UBOOT_User_Guide#BCH_Flash_OOB_Layout
- However JFFS2 can be supported with BCH8 ECC, on higher page-sized NAND
When using JFFS2 with BCH8 scheme:
- As a rule of thumb, you need to just check if following condition hold true.
NAND OOBSize >= Bad-Block-Marker(2) + BCH8_ECC (14) * (page-size/512) + File-system metadata
where:
FileSystem metadata = 8 bytes for JFFS2
FileSystem metadata = 0 bytes for UBIFS
Thus for 2K/64B NAND device using JFFS2
OOBSIZE = 64 is less than required area in OOB (2 + 14 * (2048/512) + 8 = 66)
Refer: http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/717/p/231420/815463.aspx#815463
"
http://processors.wiki.ti.com/index.php/Raw_NAND_ECC
Thank you.
BR
Vladimir
Thanks Vladimir,
I had found the answer to my question earlier, but your post was very helpful, thanks!. I now understand the JFFS2/OOB size relationship. I am indeed using a 2K/64B NAND. Turns out I have other ECC related problems, even when taking JFFS2 out of the equation.
Thanks for taking the time to reply.
-Joel