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.

AM3352: NAND boot questions

Part Number: AM3352

Hello,

We are converting from an on-die ecc part to one without ecc and I have a couple questions regarding booting from nand.

Due to eol and supply issues of the original part, this is quite urgent.

Is there documentation on the bootrom's ecc module configuration ?

Am looking specifically for the mode setting but a complete configuration would be most helpful.

Is the spare area included in any of the block's ecc calculations ?

Have seen references to the bin2nand utility and would like to get a copy of the windows version.

Our nands are preprogrammed at factory and this would help reduce any programmer setup issues.

Would also be useful to validate the software page writes.

Thank you,

David C. Evers

  • David,

    Please accept my request so that I can share the bin2nand utility with you.

    ROM documentation and the ECC calculation in general is covered in various spots of the AM335x TRM.

    I hope this helps you.
  • Ron,
    Look forward to receiving the bin2nand to help confirm my ecc setup.
    The TRM documentation is woefully inadequate, I have scrubbed through it all. Ideally, I would like to see the exact ecc setup the bootrom is using when SYSBOOT[9] is low. Problem being the Am335x spare area boot format is not a typical usage and that format does not align with any of the read sequences provided. This is further compounded trying to ecc protect the spare area. The section in the doc regarding wrapping modes and sizes is also unclear. This is a complicated and critical area and needs some better documentation.
    Regards,
    David
  • David,

    OK, thanks for the feedback on the documentation and I'll put it in front of our NAND documentation expert.

    I've sent the utility and I hope it helps clarify your questions.
  • The utility did help to provide some data to test against and it is still has potential for pre-programmed parts.

    However, the ecc values the utility is generating does not agree with what the Am3352's ecc module is producing for sector 0.

    Sectors 1-3 have the same data in both although the order is not the same due to the different program's presentation.

    Can not resolve this thread until I can get the two to agree.

    Only question on the utility is what does a 'type' parameter of 'one' mean ?

    I have tried a number of different options for the module settings and it consistently comes up with the following results on both read and write :

    The bin2nand is generating the following :

    With the setup :

      NAND type.................. RAW
      NAND page size............. 2048
      NAND spare area (bytes).... 64
      NAND block size (pages).... 64
      Correctable sectors........
      Uncorrectable sectors......
      Source file................ Boot_D
      Output file................ Boot_D
      Input image size........... 8
      Output image size.......... 131072
      Generating image...
      Page: 064/064 Sector: 4/4
      Done.

  • Am3352_ecc.docxbin2nand_ecc.docxScreen captures did not come thru the post, attaching them here.

  • David, be sure the bin2nand command is in this format:

    bin2nand -bch 8 -block <number of blocks> InputFile OutputFile

    Be sure the block size satisfies this formula
    Block size > Image size in bytes/ page size

    So if your image size is 500K, block size would be 500K/2048=244.14 or 245

    Regards,
    James
  • Okay. All that does is change the output file size. The bin2nand ecc of Sector 0 did not change.
  • Have managed a couple positive steps.

    First, wrote test code to program our boot loader into the nand using the bin2nand output file and the board booted up.
    This answers the format requirement of the Am335x boot rom and it also tells me that the spare area itself is not ecc protected.
    To me, that is not a very robust nor complete implementation.

    Using trial and error with the mode and size settings, I did come up with a method of producing the same sector 0 ecc as bin2nand.
    Can't say it really gives me much insight other than to reiterate that the documentation is lacking.
    Best approach was to read the nand in pages and disable the ecc module before reading the spare area.
    I suppose the ecc module configuration questions should go into another thread.

    David E.
  • David,

    Thanks for sharing your thoughts. I've noted the request for improved documentation for a future version of our docs.