[U-Boot] mx25 and 16x SLC NAND problem

Mo Radulovic mradulov at gmail.com
Mon Mar 1 02:35:38 CET 2010


Hello everyone,

I was wondering if anyone can shed any light on the problem I encountered
trying to get 16x Micron SLC NAND (MT29F2G16AA; 2K page, 64byte spare area
and 128K erase block) to work with Freescale i.MX258 SoC.

Description:
=========
(1) I am booting successfully from NAND.
(2) When I try to save the environment, it seems that write works (saveenv)
and I can verify that all the data is realy properly written to the  NAND
(nand dump 40000 20000)
(3) Data in the OOB area also seems logical: first 9-byte ECC sequnce
(calculated for the first 512-byte subpage  that actualy contains the data)
is different from 3 other (mutualy identical) ECC sequences calculated for
the empty subpages.
(4) reset produces :
"MXC_NAND: HWECC uncorrectable ECC error in block 2 page 128 subpage 0"
(which points to where I have my env offset set to (0x40000) with no
redundant area)
"*** Warning - bad CRC or NAND, using default environment"

My Troubleshooting:
================
* I tried using different block to store the environment and all of them
behave the same (as stated above).
* I double-checked i.MX258 datasheet to make sure that NFC (v1.1) is
properly initialized (4-symbol ECC and all relevant  NFC/CCM registers)
* I tried Freescale's version of the U-boot (released as a part of their
Board Support Package) with worse results (their u-boot version seems to be
written only for 8x NAND)
* I made sure that OOB layout used in U-boot matches what NFC data sheet
(IMX25.pdf) requires.

Supporting Info:
============
Source tree: u-boot-2009.11.1 source tree with set of Rigby patches applied
Compiler: Code Sourcery arm cross-compiler (arm-2008q3/arm-none-eabi-gcc
ver 4.3.2)
Hardware: custom-built board

Extra question:
===========
"nand dump 40000" produces the output in which all empty areas of the nand
are marked as "00 10" instead of "ff ff".  Why?

I really do appreciate all suggestions and ideas.  Thanks.

Cheers,
Momcilo Radulovic


More information about the U-Boot mailing list