Kate Alhola 2004
You should download the latest DENX ELDK and install it as descripted in the Denx docmentation. You need to have only ppx_82xx support installes. In this documentation we have asspuption that eldk is installed to /opt/eldk directory
You should download latest DENX kernel tree from their CVS server with the following commands
cvs -d :pserver:anonymous@www.denx.de:/cvsroot login cvs -z6 -d :pserver:anonymous@www.denx.de:/cvsroot co -P linuxppc_2_4_devel
Or you can obtain latest version that i have tested from katix.org downloads.
Then you need to obtain the patches from katix.org downloads. You will need iti5200.patch, spi.patch and iticoral.patch . You need to have the following files:
kate@tbebi:~/iti5200/test2> ls -l total 40251 -rw-r--r-- 1 kate users 86627 2004-11-02 16:21 iti5200.patch -rw-r--r-- 1 kate users 1799 2004-11-02 16:21 iticoral.patch -rw-r--r-- 2 kate users 40789943 2004-11-01 13:28 linuxppc_2_4_devel.cvs.20041024.tgz -rw-r--r-- 1 kate users 289464 2004-11-02 16:21 spi.patch kate@tbebi:~/iti5200/test2>
Next you need to unpack the kernel and apply the patches. There is three patches. iti5200.patch adds support for iti5200 boards and variants. It also contais some additions to i2c chip support and ppc5200 register definitions. This patch may be helpfull even if you are not using iti5200 variants. The spi.patch adds support for spi susbsystem and mmc subsystem. iticoral.patch does minimal patch to Fujitsu CoralB to support SDRAM chip used in itcoral board.
After patches has been aplied, you can chose default kernel configuration to use. iti5200_defconfig is used when you like to use serial port console conencted in PSC1. iti5200_coralp_defconfig is used with lcd monitor connected to coralp board and usb keyboard used as a console. When you use iti5200_coralp_defconfig you don't see any console messages coming to serial console becouse they appear to LCD. If you use iti5200_defconfig and coralp board you see linux logo and curson on LCD but console messages come to a serial console.
It is possible to use these config files with lite5200 board but there is some differences. Lite5200 has differential mode USB tranceiver interface, iti5200 has single ended mode, so if you try to use these configs with lite5200 board remember change the usb mode.
kate@tbebi:~/iti5200/test2> cd linuxppc_2_4_devel/ kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> patch -p1 <../iti5200.patch kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> patch -p1 <../spi.patch kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> patch -p1 <../iticoral.patch kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> cp arch/ppc/configs/iti5200_defconfig .config kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> export PATH=$PATH:/opt/eldk/usr/bin kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> make oldconfig kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> make uImage kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> make modules kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> make modules_install kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> cp arch/ppc/boot/images/uImage /tftpboot/kx2 kate@tbebi:~/iti5200/test2/linuxppc_2_4_devel> cp arch/ppc/boot/images/uImage /ppcroot/tmp/
In the previous example we copied a kernel image to a ppc nfs root/tmp directory. We need to use flashcp or nandwrite to copy the kernel image to a nand flash or some other way to pad it for flash block multiple and then use cp. For some reason it looks a like that mtdutils and mtd in denx kernel are incompatible. nandwrite tries to use MEMGETBADBLOCK ioctl and it is not at all denx kernel version of mtd drivers. Flashcp gets a write error in fifth block that it writes. At the moment, the easiest way is to comment out MEMGETBADBLOCK ioctl from flashwrite and then use patched flash write. In the future, there is coming a Katix embedded linux patch that upgrades mtd and ffs. This patch is tested but not yet integrated as a patch for distribution.
The /dev/mtd0 is used for boot kernel and /dev/mtd1 / mtdblock1 is used as a root filesystem.
bash-2.05b# eraseall /dev/mtd0 bash-2.05b# /tmp/nandwrite -p /dev/mtd0 /tmp/uImage bash-2.05b# mount -t jffs2 /dev/mtdblock1 /mnt
Next we should set up u-boot for booting from flash
(C) 2004 Katix.org maintainers. All rights reserved. http://www.katix.org