[U-Boot-Users] Difference between bootm and run flash_self commands

Ben Warren bwarren at qstreams.com
Tue Mar 13 16:15:59 CET 2007

--- Senthil Shanmugham <neorebel at gmail.com> wrote:

> Hi All,
> I was wondering about the difference between the
> bootm and run flash_self
> commands. I understand that bootm command
> uncompresses and boots the kernel
> from a given memory location. The board hangs when I
> try to use bootm
> command to load the kernel whereas it works
> perfectly when I use "run
> flash_self" command.
flash_self is a macro.  Look below...

> The environment variables is same for both the
> scenarios. I've included the
> environment variables as well as command outputs
> below.
> Enviroment variables
> ==================
> => printenv
> bootcmd=run flash_self
> baudrate=115200
> loads_echo=1
> preboot=echo;echo Type "run flash_nfs" to mount root
> filesystem over
> NFS;echo
> netdev=eth0
> hostname=taishan
> nfsargs=setenv bootargs root=/dev/nfs rw
> nfsroot=${serverip}:${rootpath}
> ramargs=setenv bootargs root=/dev/ram rw
> addip=setenv bootargs ${bootargs}
> bootargs ${bootargs} console=ttyS1,${baudrate}
> flash_nfs=run nfsargs addip addtty;bootm
> ${kernel_addr}

> flash_self=run ramargs addip addtty;bootm
> ${kernel_addr} ${ramdisk_addr}

It does much more than bootm, such as telling the
kernel you're using an initrd for rootfs(ramargs),
passing network configuration, which isn't likely
causing your problem (addip), and of course setting up
the console port, which probably is causing your
problem (addtty).  The definitions of these items are
obscured by your printout, but they're not trivial.
Type 'printenv addtty', for example.


More information about the U-Boot mailing list