Skip to main content.

6. Embedded Linux Configuration

6.1. Download and Unpack the Linux Kernel Sources

You can download the Linux Kernel Sources from our anonymous git server at http://git.denx.de/. To checkout the module for the first time, proceed as follows:

bash$ cd /opt/eldk/usr/src
bash$ git clone git://git.denx.de/linux-2.6-denx.git linux-2.6-denx
bash$ cd linux-2.6-denx
bash$ git checkout -b duts remotes/origin/44x/canyonlands
Branch duts set up to track remote branch 44x/canyonlands from origin.
Switched to a new branch 'duts'
bash$

6.2. Kernel Configuration and Compilation

The canyonlands board is fully supported by DENX Software Engineering. This means that you will always be able to build a working default configuration with just minimal interaction.

Please be aware that you will need the "powerpc" cross development tools for the following steps. Make sure that the directory which contains the binaries of your ELDK are in your PATH.

To be sure that no intermediate results of previous builds are left in your Linux kernel source tree you can clean it up as follows:

bash$ make mrproper

The following command selects a standard configuration for the canyonlands board that has been extensively tested. It is recommended to use this as a starting point for other, customized configurations:

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP- 44x/canyonlands_defconfig


TIP Note: The name of this default configuration file is arch/powerpc/configs/44x/canyonlands_defconfig . By (recursively) listing the contents of the arch/powerpc/configs/ directory you can easily find out which other default configurations are available.

If you don't want to change the default configuration you can now continue to use it to build a kernel image:

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP- uImage

Otherwise you can modify the kernel configuration as follows:

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP-  config

or

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP-  menuconfig

ALERT! Note: Because of problems (especially with some older Linux kernel versions) the use of "make xconfig" is not recommended.

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP- uImage

The make target uImage uses the tool mkimage (from the U-Boot package) to create a Linux kernel image in arch/powerpc/boot/uImage

which is immediately usable for download and booting with U-Boot.

In case you need a DTB to boot your linux kernel, you need the following step:

bash$ make canyonlands.dtb

In case you configured modules you will also need to compile the modules:

make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP- modules

add install the modules (make sure to pass the correct root path for module installation):

bash$ make ARCH=powerpc CROSS_COMPILE=ppc_4xxFP- INSTALL_MOD_PATH=/opt/eldk-4.2/ppc_4xx modules_install

6.3. Installation

For now it is sufficient to copy the Linux kernel image into the directory used by your TFTP server:

bash$ cp arch/powerpc/boot/uImage /tftpboot/uImage

5.14.1. Boot Count Limit 1. Abstract 7. Booting Embedded Linux
Prev Home Next