[U-Boot] Building U-Boot image with predefined environment

trh178 todd.haldeman at legrand.us
Thu Jul 5 15:14:06 CEST 2012


I am taking over a project originally done by somebody else and not
documented at all. I am not very familiar with U-Boot in general, so I am
effectively starting from scratch.

My current issue is this: I have a U-Boot image that I can load onto my
board that, upon start, says it is autobooting and then immediately prompts
the user for 'ethaddr'. After you give it an ethaddr, it will get an IP via
dhcp and, using tftp, get the rest of the environment/kernel/filesystem from
a local server. I cannot use this image anymore though. I had to make a
slight change to the config file for U-Boot.

I have successfully rebuilt U-boot and flashed it onto the board. When it
boots now though, it says it will autoboot in 3 seconds (instead of 1
previously), and then it fails autoboot because of a bad magic number and
drops me into the UBoot> prompt. It does not prompt me for an 'ethaddr'.
This leads me to believe that the previous image was built with a very basic
predefined environment (e.g. 'do this if you dont have an ethaddr set, or
else if you do then get an ip via dhcp, etc...). I know that after I get an
IP address the board uses tftp to load the full environment because, along
with a kernel.img and a filesystem.img, there is also a bootscript.img on
the tftp server.

My lack of knowledge led me to only one solution. The first image that works
right now must have been built with a basic environment script included? Is
this possible? and if so, how do I do this? It seems like if I can get my
NEW image to act as the old one on startup, then once it HAS an ip address,
the full environment can be loaded via tftp like before.

Thanks ahead of time for the help,
-- 
View this message in context: http://old.nabble.com/Building-U-Boot-image-with-predefined-environment-tp34116429p34116429.html
Sent from the Uboot - Users mailing list archive at Nabble.com.



More information about the U-Boot mailing list