User guide

31 GR-LEON4-ITX Development Board
Quick Start Guide
Next we need to build a Linux kernel image that U-boot can handle. U-Boot needs a header
to know how to interpret the binary images. The images support compression and CRC
verifying. To create an image, the mkimage tool must be in the system path. The Linux
kernel has a prepared build target for generating u-boot images (uImage):
jan@jan:~/Linux/snapgear-2.6-p41$ cd linux-2.6.21.1/
jan@jan:~/Linux/snapgear-2.6-p41/linux-2.6.21.1$ make ARCH=sparc \
CROSS_COMPILE=sparc-linux- uImage
CHK include/linux/version.h
CHK include/linux/utsrelease.h
… removed output ...
sparc-linux-ld -Tdata 0x00040000 -r -b binary arch/sparc/boot/uImage -o
arch/sparc/boot/uImage.o
Image arch/sparc/boot/uImage is ready
jan@jan:~/Linux/snapgear-2.6-p41/linux-2.6.21.1$
In order to interact with the pre-built version of U-boot the board must be connected to a
monitor and a USB keyboard. The uImage created above should be placed in the root of a
TFTP sever and a Ethernet cable should be connected to the GR-LEON4-ITX board's
second (top) Ethernet port.
After the necessary preparations have been made reset the board and press a key on the
USB keyboard to stop the U-boot boot process. When presented with the U-boot prompt
issue the following commands (see the U-boot documentation for more commands and the
meaning of the commands below):
=> setenv severip <ip address of tftp server>
=> saveenv
=> run getkernel
=> sf probe
=> sf erase 400000 200000
=> sf write 40200000 400000 $(filesize)
To see information about the downloaded image issue the command:
=> iminfo
It is also possible to update the u-boot image using GRMON. First interact with U-boot and
issue the commands:
=> sf probe 0
=> sf erase 400000 200000
Then the Linux image can be built with:
make ARCH=sparc CROSS_COMPILE=sparc-linux- UIMAGE_FLASHADDR=0x00400000 uImage
and loaded in GRMON via (note the .o suffix):
grmon> spim flash load arch/sparc/boot/uImage.o
© Aeroflex Gaisler AB March 2013, Rev. 0.3