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.

Booting a brick'd EVM from MMC

Let me preface this with "I'm an OMAP and Linux noob, please be nice!"

So we were loaned a Mistral OMAP 35x EVM by our distributor.  The NAND is bricked and I'm trying to build an MMC card that will boot Linux.

I have OMAP35x-PSP-SDK-02.01.01.08.  I'm not yet set up to rebuild anything (but we're working on that).  But there are pre-compiled images on the distribution, I'd figure they should be pretty generic.

So I copied x-load.bin.ift and u-boot.bin to my newly reformatted SD card, renamed x-load to MLO, and I can fire up u-boot.  So far so good.

Now, to boot linux.  I copy uImage over to the SD card.  U-boot doesn't find it.  It mysteriously says:

## Booting kernel from Legacy Image at 80000000 ...
   Image Name:   Linux-2.6.29-rc3-omap1
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2106608 Bytes =  2 MB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... Bad Data CRC
ERROR: can't get kernel image!

Question#1:  Where is u-boot getting the image name, and how can I point it at uImage?  printenv doesn't seem to give any clues (in fact the bootfile parameter is uImage!).

But I'm persistant.  I rename uImage to be the given filename.  Still no joy.

I'm not done yet.  Inspired by the .scr files in the beagleboard recovery procedure (http://code.google.com/p/beagleboard/wiki/BeagleboardRevCValidation) I figure I'll manually boot the kernel.

OMAP3_EVM # fatload mmc 1 80200000 uImage      gives the error message:

** Unable to use mmc 1:1 for fatload **

I get similar errors for fatls.  Changing the device number doesn't seem to help either.

My sys_boot switches (SW4) are set to ON-OFF-OFF-ON-ON-OFF (order 1->6).

Question #2: What do I need to do to get u-boot to recognize the MMC interface?  Is there a way to determine what interfaces are supported by a particular u-boot build?

Thanks in advance,

Ken

 

 

  • It sounds like you have been mostly successful, often getting the board to boot up to U-Boot out of an SD card can be a challenge (for example the long and popular thread here).

    Ken Brown said:
    Question#1:  Where is u-boot getting the image name, and how can I point it at uImage?  printenv doesn't seem to give any clues (in fact the bootfile parameter is uImage!).

    I am not sure what it is trying to do by default there, it sounds like there is some problem in your U-Boot environment variables though, in general you define how U-Boot will get the kernel image and execute it in your U-Boot environment variables. In this case you have to run commands to tell U-Boot to load the uImage from the MMC/SD before you can run it. One good example set of U-Boot variables is below, which assumes you have a dual partition SD card and your file system is on the second partition:

    setenv bootargs 'console=ttyS2,115200n8 root=/dev/mmcblk0p2 rw rootdelay=1'
    setenv bootcmd 'mmcinit;fatload mmc 0 80300000 uImage;bootm 80300000'

    Ken Brown said:
    Question #2: What do I need to do to get u-boot to recognize the MMC interface?  Is there a way to determine what interfaces are supported by a particular u-boot build?

    My initial suspicion is that you are getting an error loading the uImage file because you did not run mmcinit yet, this should bring up the MMC interface. As to determining what U-Boot can do, you can look into the source for the particular version you have to see what was put into it (I have not gone digging for a release notes, and I do not have an install in front of me at the moment), beyond that there is a lot of good information on http://www.denx.de/wiki/DULG/Manual about various commands you can use, though as you suggest some of these may be newer than the U-Boot we have and there may be some extra ones put in by TI.

  • Thanks for the info Bernie.  Would've followed up sooner, but I had a 3-day weekend.   [:)]

    I'm not sure where the U-boot environment variables come from, but I'll see if I can figure it out.  Given that I'm starting with a brick'd NAND device and a freshly formatted MMC with pre-build files copied onto it, I'm guessing they're coming from the x-loader image, but who knows.

    mmcinit.  Doh.  <slaps forehead>  There it is, right in command list.  Yup, that gets me farther.  Still haven't figured out the right boot command (I only have a single partition on my SD card), the best I've been able to do so far complains about ram filesystem extending beyond physical memory.  But I've still got more things to try.

     

     

    Ken

     

     

     

  • Ken Brown said:
    I'm not sure where the U-boot environment variables come from, but I'll see if I can figure it out.  Given that I'm starting with a brick'd NAND device and a freshly formatted MMC with pre-build files copied onto it, I'm guessing they're coming from the x-loader image, but who knows.

    If you are starting out fresh than U-Boot will have some pre defined environment variables in it, than depending on the particular build of U-boot you have they will be stored in some non volatile location when you run 'saveenv', probably your NAND though I have seen U-Boots which will save to the MMC. In any case you just need to adjust these to boot your board however you choose.

    Ken Brown said:
    Still haven't figured out the right boot command (I only have a single partition on my SD card), the best I've been able to do so far complains about ram filesystem extending beyond physical memory.  But I've still got more things to try.

    Assuming you have a Linux PC handy that can run a NFS server I would suggest booting the filesystem over NFS as discussed in the EVM getting started guide, at least for development purposes since this gives you an easy way to move files between the board and the development PC.