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.

AM3358: uboot bch4

Part Number: AM3358

Tool/software:

I am working on a project which requires BCH4 ECC scheme for NAND.. I searched all the uboot revisions but none have implementation for BCH4 ECC.

Any help(quick response)  on this is really appreciated .

GPMC details :

AM335x GPMC controller

  • In reference to AM335x TRM "26.1.8.4 NAND", only BCH8/BCH16 is supported by AM335x ROM.
    1/. ROM loads the first stage BL (i.e. SPL) using either BCH8 or BCH16 based on nand device OOB size etc...
    2/. It is practically necessary to configure the same BCH scheme (BCH8 or BCH16) in u-boot/kernel...
    => BCH4 is not supported in AM335x u-boot
    Best,
    -Hong

  • hi,Hong
    The whole machine cannot be turned on normally after abnormal power failure. After flashing the flash again, it works normally with a defect rate of 1% (approximately 10 units out of 1k pcs per month). It has been preliminarily confirmed that it is caused by damaged flash files.

    The product software kernel adopts version 3.2.0 The client conducted the following tests and the related results are as follows:

    1. When MLO reads uboot from nand, Hamming verifies that it can start normally;

    2. Changing a certain bit in uboot, hoping that ECC verification could correct the error, but it did not, resulting in uboot being unable to start;

    3. It seems that the ELM of AM335x is not working properly, resulting in ineffective NAND ECC during the uboot phase.

    I hope to seek advice on the following questions:

    1.What is the working mechanism of Elm? Is there any relevant documentation available to provide;

    2. What are the common factors that cause ECC verification to be invalid;

    3.I need to use the yaffs2 file system, but if I use BCH8, the oob area won't be enough. So I want to change it to BCH4. Why is BCH4 not supported? Only supporting BCH8, how to support BCH4, and what software changes should be made;

    4.Will there be bit flipping when AM3358 reads NAND Flash?

    5. How to implement a power-off protection software and hardware avoidance mechanism;

    thanks,

  • Only BCH8/BCH16 are supported by AM335x ROM.
    Please refer to "26.1.8.4 NAND" in AM335x TRM on GPMC-NAND support in AM335x ROM
    https://www.ti.com/lit/pdf/spruh73
    "26.1.8.4.1 Features"
    - Support for large page size (2048 bytes + 64 spare bytes) or very large page size 4096 bytes + 128/218 spare bytes)
    - ECC correction : 8bits/sector for most devices (16b/sector for devices with large spare area)
    Best,
    -Hong