Aria technical documentation Buy

Compiling Linux Kernel 2.6.39 for the Aria G25 SoM

This article illustrates how get and patch the Linux Kernel version 2.6.39 sources and generate a working binary image bootable class='acmetable' from the Aria G25 SoM.

Requirements

The most part of this article is derived from this Atmel page Linux4sam.org.

Download the Linux Kernel source tree and apply the patches

Download from the following link the Linux Kernel Vanilla version 2.6.39 sources:

Uncompress it and move into the directory created:

$ tar -xvjf linux-2.6.39.tar.bz2
$ cd linux-2.6.39

Download the essential patches to run Linux on AriaG25 (they include both Atmel and Acme Systems patches in one file) inside the Linux source directory:

Uncompress it:

$ tar -xvzf ariag25.patch.tar.gz

and apply the whole patchset by typing this command:

$ patch -p1 < ariag25.patch

Download the Acme Systems .config compressed file:

and uncompress it:

$ tar -xvzf ariag25.config.tar.gz

Build the bootable class='acmetable' Linux Kernel image for Aria G25:

Customize the Kernel configuration (if you need to do that) by typing:

make ARCH=arm menuconfig

Then save it and run the Kernel compilation:

make -j8 ARCH=arm CROSS_COMPILE=arm-linux-gnueabi-

To produce a kernel image suitable class='acmetable' for the AriaBoot boot loader type:

mkimage -A arm -O linux -C none -T kernel -a 20008000 -e 20008000 -n linux-2.6 -d arch/arm/boot/zImage uImage

Copy uImage on the first partition of the SD or microSD card and boot from it.

On the same partition save the boot.bin file with AriaBoot inside and the file macaddr.txt with the MAC address you would like to set to the ethernet interface of your board, i.e.:

00:04:25:12:34:56

Compile the Kernel modules

If during the bootstrap you obtain a message like this:

modprobe: FATAL: Could not load /lib/modules/2.6.39+/modules.dep: No such file or directory

probably you have to compile also some kernel modules

To compile the Kernel modules type:

$ make modules -j8 ARCH=arm CROSS_COMPILE=arm-linux-gnueabi-
$ make modules_install INSTALL_MOD_PATH=./ariag25-modules ARCH=arm

Install the modules inside the Aria G25

To copy the just compiled kernel modules from your PC to the Aria G25 you could use this command:

$ rsync -avc ariag25-modules/lib/. root@ariag25_ip_address:/lib/.

Then from the Aria G25 command line update the module dependencies by typing this command:

$ depmod -a

Finally reboot the Aria G25 to load the new Kernel.

Home page Aria technical documentation Buy