Freescale application note AN4033 describing how to boot the MPC5125 MPU from NAND flash on the TWR-MPC5125 board, including U-Boot setup.
This application note (document number AN4033, Rev. 0, 01/2010) describes the procedures to perform NAND flash boot with the Freescale MPC5125 MPU. The hardware platform used in the example is a TWR-MPC5125 board, and the note is based on the MPC5125 Microcontroller Reference Manual (MPC5125RM) and the schematics of the TWR-MPC5125.
It covers board preparation, the MPC5125 reset and I/O control settings that affect NAND boot, the silicon boot behavior of the NAND Flash Controller, and the U-Boot NAND flash boot software. It explains how to add NAND flash boot support to U-Boot, which files are modified, and describes the nand_spl source code (nandstart.S and nandload.c). An appendix gives the TWR-MPC5125 board layout.
| Boot block row addresses | 0, 256, 512, and 768 |
|---|---|
| Boot burst read size | 4 pages, a total of 4 KB |
| ECC correction depth | 32 bits errors in an NFC page |
| USB-to-serial port setting | 115,200 baud, 8 data bits, 1 stop bit, no hardware handshaking |
| NAND flash on TWR-MPC5125 | Micron M29F64G08CFABA, 8-bit bus width, (4096 + 224 bytes) pages |
| Boot image address range after boot | 0 to 3983 |
| NAND flash offset for u-boot.bin | 0x0080_0000 |
You must turn SW1 positions 1 and 2 to ON so that the board boots from NAND flash.
ROMLOC[1:0] selects the boot device, and a value of 01 selects a NAND boot.
Use make clean, then make ads5125_nand_config, then make; the resulting images are placed in the u-boot source tree and the nand_spl sub-directory.
Set the serial console to 115200, 8-N-1, attach the board through the USB-to-serial port, and reset the board.