U-Boot Porting

From Linux/Xtensa
Revision as of 05:07, 16 April 2008 by Chris (talk | contribs) (New page: == Adding a new Platform (Board) == The easiest way to add new platform to U-Boot is usually to start from a similar board and modify the files as needed. The first step is to add the boa...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Adding a new Platform (Board)

The easiest way to add new platform to U-Boot is usually to start from a similar board and modify the files as needed. The first step is to add the board to the main Makefile in the root directory.

Unlike other architectures, the processor configurations (variants) are defined inside the Xtensa include directory.

The following version allows for arbitrary Xtensa processor configuration. Instead of make <board>_config , it requires an additional name to specify the <variant>. This is the name of the processor configuration. The configuration make variant_board_config , for example, the following command will configure U-Boot for the xtav60 board with a dc232l processor configuration: make dc232l_xtav60_config

%<board>_config: unconfig
       @$(MKCONFIG) xtensa xtensa xtav60 avnet NULL $(*:_=)
       @echo "VARIANT = $(*:_=)" >> $(obj)include/config.mk


<board>_config: unconfig
       @$(MKCONFIG) xtensa xtensa <board> <vendor> NULL variant


All board specific files are concentrated in one directory (the <vendor> sub-directory is optional):

board/[<vendor>]/<board>

This directory typically contains a README file describing the board and features, files for the build system ( Makefile and config.mk ), and one or more source files to initialize the board.


There is one additional configuration file in the include/configs/ directory, which is typically named after the board: <board>.h . This file contains various board-specific macro definitions, such as FLASH location, device registers, etc.


You should include addrspace.h from the Xtensa include directory. This file provides macros to

#include <asm/addrspace.h>


Adding a new Processor Configuration