This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

OMAP35x EVM SD boot and bootargs



I am having trouble booting the Mistral EVM board using an SD card.  I looked over the existing "booting..." threads but I'm still missing something.

For the build machine, I am running VMware 6.52 with Ubuntu 8.04 and CodeSourcery version 2007q3 as the cross compiler.

Using the “Getting Started v0.97” guide I installed the toolchain and source.  I then followed the steps to build u-boot, kernel, x-loader, and “full ramdisk image”.

Everything went fine and I created MLO, u-boot.bin, uImage, and ramdisk.gz

I then formatted a 2 gig SD card using the “HD USB Disk Storage Format Tool, V2.0.6” as fat 32 so that the EVM could read the SD card.

Next, I put MLO (first), u-boot.bin, uImage, and ramdisk.gz on the SD card.

I then changed the SW4 switches on the board as shown in the “Getting Started Guide v0.97” to:

 UUUUUDDD (U= up/off, D=down/ON) I have a Micron board.
 87654321

The guide shows the switches in reverse order (8-1) so I copied that here.

Anyway, here’s what the boot looks like:

Texas Instruments X-Loader 1.41
Starting X-loader on MMC
Reading boot sector

152180 Bytes Read from MMC
Starting OS Bootloader from MMC...
Starting OS Bootloader...


U-Boot 1.1.4 (May 28 2009 - 08:29:00)

OMAP3-GP rev 2, CPU-OPP2 L3-165MHz
OMAP3EVM 1.0 Version + mPOP (Boot NAND)
DRAM:  128 MB
NAND:256 MiB
*** Warning - bad CRC or NAND, using default environment

In:    serial
Out:   serial
Err:   serial
Reseting CHIP... Done
LAN9x18 (0x01150002) detected.
Setting mac address: aa:bb:cc:dd:ee:ff
start Auto negotiation... (take ~2sec)
Auto negotiation failed
Hit any key to stop autoboot:  0
bootcmd is not configured
OMAP3EVM #

Once at the # prompt, printenv yields:

OMAP3EVM # printenv
bootargs=mem=128M console=ttyS0,115200n8 noinitrd root=/dev/mtdblock4 rw rootfst
ype=jffs2
bootcmd=echo bootcmd is not configured
bootkernel=onenand read 0x80000000 0x280000 0x400000 ; run bootkernel_1
bootkernel_1=bootm 0x80000000
bootdelay=0
baudrate=115200
ethaddr=aa:bb:cc:dd:ee:ff
ipaddr=192.168.1.10
serverip=192.168.1.20
gatewayip=192.168.1.1
netmask=255.255.255.0
bootfile="uImage"
stdin=serial
stdout=serial
stderr=serial
mmcboot=mmcinit;fatload mmc 0 0x80000000 uImage;fatload mmc 0 0x81600000 ramdisk
.gz;bootm 0x80000000

Environment size: 531/131068 bytes
OMAP3EVM #

 

I think I need to update the boot arguments/command to finish the boot process.  I don't know how, what, or where, so any help on this would be great.  I have the Micron memory board.  Also, I read a thread about forgetting to set the bootdelay variable so please comment on that so I can avoid that problem.

This is my first post!

  • Hi,

    I can see from the logs that your bootcmd is not configured. You can set the bootcmd as setenv bootcmd 'mmcinit;fatload mmc 0 0x80000000 uImage;fatload mmc 0 0x81600000 ramdisk.gz;bootm 0x80000000'.

    Make sure that all the required images like u-boot,uImage,ramdisk.gz are present on the SD card.

    You can also try by just giving run mmcboot at the u-boot command prompt.

    Thanks,

    Prathap.

  • Thanks Prathap, I finally got it working.  The run mmcboot (or changing the bootargs) gets the demo to load but the unit keeps throwing these types of erors even though the picture book demo runs fine:

    mtd->read(0x1f9d4 bytes from 0x3e062c) returned ECC error
    mtd->read(0x20 bytes from 0x3fffe0) returned ECC error
    mtd->read(0x400 bytes from 0x400000) returned ECC error
    mtd->read(0x1fa9c bytes from 0x400564) returned ECC error

    In talking with Mistral and a colleague it was found that the root file system needs to be run out of ramdisk, not flash.  So, we need to set that up.  My colleague sent me this file to help (I "sent" the file via Tera Term to setup the environment):

    setenv get_kernel      run nand_kernel
    setenv get_initrd      run nand_initrd
    setenv nand_kernel     nand read.i 0x80000000 280000 200000
    setenv nand_initrd     nand read.i 0x81600000 780000 1000000
    setenv mmc_kernel      fatload mmc 0 0x80000000 uImage
    setenv mmc_initrd      fatload mmc 0 0x81600000 ramdisk.gz

    setenv tftp_kernel     tftp 0x80000000 uImage
    setenv tftp_initrd     tftp 0x81600000 ramdisk.gz
    setenv bootargs_rd     mem=128M console=ttyS0,115200n8 root=/dev/ram0 initrd=0x81600000,40M ramdisk_size=40960
    setenv bootargs_fs     mem=128M console=ttyS0,115200n8 noinitrd root=/dev/mtdblock4 rw rootfstype=jffs2
    setenv bootargs_nfs    mem=128M console=ttyS0,115200n8 noinitrd rw root=/dev/nfs nfsroot=/home/msj2105/OMAPtarget,nolock
    setenv addip           setenv bootargs \$(bootargs) ip=\$(ipaddr):\$(serverip):\$(gatewayip):\$(netmask):\$(hostname):eth0:on
    setenv boot_rd         run get_kernel\; run get_initrd\; setenv bootargs \$(bootargs_rd)\; run addip\; bootm 0x80000000
    setenv boot_fs         run get_kernel\; setenv bootargs \$(bootargs_fs)\; run addip\; bootm 0x80000000
    setenv boot_nfs           run get_kernel\; setenv bootargs \$(bootargs_nfs)\; run addip\; bootm 0x80000000
    setenv mmcboot_init    mmcinit\; run mmc_kernel\; run mmc_initrd
    setenv boot_mmc        run mmcboot_init\; setenv bootargs \$(bootargs_rd)\; bootm 0x80000000
    setenv bootcmd         run boot_rd
    setenv bootdelay       20
    setenv bootkernel
    setenv bootkernel_1

    So, if you do #run boot_mmc it copies the ramdisk.gz into ram and runs from there.  This runs without error.

    Thanks for your help.  Hopefully this helps the next newbie boot successfully!

     

     

  • The ramdisk.gz is a compressed image of the 'raw' filesystem. It cannot be used as a 'natural' filesystem.

    To do so, you can extract the NFS filesystem - included as a separate tarball -  on the SD card. Ensure that you have root permissions (as 'root' user or via 'sudo') so that the device nodes are copied properly.

  • I wanted to close the loop on this.  Everyone was right, I didn't have boot args and I was trying to use a raw filesystem directly off the flash card. I ended up loading the raw filesystem into RAM for my testing.

    Thanks for your help!