User`s guide

Porting U-Boot from an i.MX53 Reference Board to an i.MX53 Custom Board
i.MX53 System Development User’s Guide, Rev. 1
11-2 Freescale Semiconductor
NOTE
U-Boot project developers recommend adding any new board to the
MAKEALL script and to run this script in order to validate that the new
code has not broken any others platform build. This is a requirement if you
plan to submit a patch back to the U-Boot community. For further
information, consult the U-Boot README file.
4. Rename board/freescale/mx53_<custom board name>/mx53_<reference board name>.c as
board/freescale/mx53_<custom board name>/mx53_<custom board name>.c.
5. Adapt any fixed paths. In this case, the linker script board/freescale/mx53_<custom board
name>/u-boot.lds
has at least two paths that must be changed
Change board/freescale/mx53_<reference board name>/flash_header.o to
board/freescale/mx53_<custom board name>/flash_header.o
Change board/freescale/mx53_<reference board name>/libmx53_<reference board name>.a
to board/freescale/mx53_<custom board name>/libmx53_<custom board name>.a
6. Change the line COBJS := mx53_<reference board name>.o (inside
board/freescale/mx53_<custom board name>/Makefile) to COBJS := mx53_<custom board
name>.o
NOTE
The remaining instructions build the U-Boot manually and do not use LTIB.
7. Create a shell script under <UBOOT_DIR> named build_u-boot.sh.
The file’s contents are now:
#!/bin/bash
export ARCH=arm
export CROSS_COMPILE=<path to cross compiler/prefix> (e.g.
PATH:/opt/freescale/usr/local/gcc-4.1.2-glibc-2.5-nptl-3/arm-none-linux-gnueabi/b
in/arm-none-linux-gnueabi-
export PATH=$PATH:<path to compiler>
make mx53_<custom board name>_config
make
8. Compile U-Boot using $./build_u-boot.sh
9. If everything is correct, you should now u-boot.bin as proof that your build setup is correct and
ready to be customized.
The new i.MX53 custom board that you have created is an exact copy of the i.MX53 reference board, but
the boards are two independent builds. This allows you to proceed to the next step: customizing the code
to suit the new hardware design.
11.3 Customizing the i.MX53 Custom Board Code
The new i.MX53 custom board is part of the U-Boot source tree, but it is a duplicate of the i.MX53
reference board code and needs to be customized.
The DDR technology is a potential key difference between the two boards. If there is a difference in the
DDR technology between the two boards, the DDR initialization needs to be ported. DDR initialization is