Olimex CS-E9302

Using MMC/SD card with Olimex CS-E9302

I have added MMC/SD card support for Olimex's CS-E9302. I successfully booted Debian GNU/Linux Etch from an SD card, log is here
Warning: this is an experimental code!


linux-2.6.24-rc8_ep93xx_mmc.patch.gz: Patch for kernel 2.6.24-rc8 (2.6.24.x) can be downloaded here. Card detection is working in this version!
cs-e9302_root2.tar.gz: I removed the udev daemon, because it caused errors. It is a root filesystem for CS-E9302 which contains Debian Etch. It is based on the root filesystem of SAM9-L9260. Username: root, password: olimex.

linux-2.6.24-rc7_ep93xx_mmc.patch.gz (old): Patch for kernel 2.6.24-rc7 can be downloaded here. Card detection does not work, thus you must insert your card before booting and you should not remove the card.
cs-e9302_root.tar.gz (old): There is a root filesystem for CS-E9302 which contains Debian Etch. It is based on the root filesystem of SAM9-L9260. Username: root, password: olimex.

u-boot-1.3.3_cs-e9302.patch: Patch for U-Boot 1.3.3 to support CS-E9302 boards.

You can report bugs on Sparkfun's forum. Or leave a comment on the bottom of the page.


Cirrus Logic's GCC compiler downloaded and installed (http://arm.cirrus.com/files/tools/arm-linux-gcc-4.1.1-920t.tar.bz2) or ELDK >= 4.0 (http://www.denx.de/wiki/view/DULG/ELDKAvailability http://ftp.sunet.se/pub/Linux/distributions/eldk/4.1/arm-linux-x86/iso/arm-2007-01-21.iso)

I used Debian GNU/Linux 4.0 Etch, but other Linux distributions should work.

I recommend to use U-Boot. You can download the patch here for U-Boot 1.3.3.

How to compile the kernel?

  1. Download, unpack Linux and apply the patch.
  2. Configure the kernel
  3. Compile the kernel
$ wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-
$ wget http://dev.ivanov.eu/projects/cs-e9302/linux-2.6.24-rc8_ep93xx_mmc.patch.gz
$ tar -xjf linux-
$ cd linux-
$ zcat ../linux-2.6.24-rc8_ep93xx_mmc.patch.gz|patch -p1
patching file arch/arm/mach-ep93xx/core.c
patching file cs-e9302_kernel_config
patching file drivers/net/arm/ep93xx_eth.c
patching file drivers/net/arm/ep93xx_eth.h
patching file drivers/spi/Kconfig
patching file drivers/spi/Makefile
patching file drivers/spi/spi_ep93xx.c
patching file include/asm-arm/arch-ep93xx/ep93xx-regs.h
$ cp cs-e9302_kernel_config .config
$ make ARCH=arm oldconfig
$ make ARCH=arm CROSS_COMPILE=arm-linux- uImage

Instead of uImage you can create zImage or whatever you want.

How to copy root filesystem to MMC/SD card?

  1. Backup your MMC/SD card. All files will be deleted!
  2. Download, unpack the root filesystem.
  3. Mount card and untar package.
  4. Umount card.
Your device node can be sda1, sdc1 instead of sdb1! Be careful!
Note: You can change the partition type to 0x83 (Linux) with fdisk, but it is not necessary.
$ wget http://dev.ivanov.eu/projects/cs-e9302/cs-e9302_root2.tar.gz
$ mkfs.ext3 -L root /dev/sdb1
$ mount /dev/sdb1 /mnt
$ cd /mnt
$ tar -xjf ~/cs-e9302_root2.tar.gz
$ umount /mnt

How to boot the kernel?

You should use the following boot arguments if you want to use your MMC/SD card as root filesystem:
console=ttyAM root=/dev/mmcblk0p1 rootdelay=5

Previous page: MSP430-4619LCD Sample project
Next page: Boa FM-radio