[U-Boot-Users] Running U-Boot as a standalone application

VanBaren, Gerald (AGRE) Gerald.VanBaren at smiths-aerospace.com
Wed Jan 14 23:09:52 CET 2004


> -----Original Message-----
> From: u-boot-users-admin at lists.sourceforge.net
> [mailto:u-boot-users-admin at lists.sourceforge.net]On Behalf Of 
> Kerl, John
> Sent: Wednesday, January 14, 2004 4:46 PM
> To: 'u-boot-users at lists.sourceforge.net'
> Subject: [U-Boot-Users] Running U-Boot as a standalone application
> 
> 
> Hello:
> 
> Another newbie question, I'm afraid ...
> 
> What I am trying to do is run another copy of U-Boot from SRAM, i.e.
> treating U-Boot #2 as a standalone application to be loaded by U-Boot
> #1.  This way I don't have to overwrite the boot code stored in the
> flash.

[snip] 

> 
> which is a machine check in PITException.  I can and will debug this
> further, but I wonder if some things are already known.  Namely:
> 
> *	What I'm doing is re-running all the init code.
> 	This is overkill, since the CPU has already been initialized,
> 	but it is easiest to code, since I just need to modify the
> 	.lds et al.
> 
> *	The other extreme would be to re-run none of the init code
> 	(except installing handlers, etc.), which I don't mind
> 	doing except that it sounds like a several-day project.
> 
> *	Is there a happy medium?
> 
> *	There is a __DEBUG_START_FROM_SRAM__ macro which I see in
> 	the code, but it doesn't appear to be used very many places.
> 
> *	I think someone else out there must have tried something
> 	similar before ... however, if there's something in the
> 	U-Boot manual on this topic, I've missed it.
> 
> Thanks for any and all info, and for your patience. :)

This is a FAQ.  People have successfully run out of RAM, but doing that is discouraged since you have to have as much or more very low level knowledge as running out of flash.  Portions of the re-init are Bad, Real Bad to run twice.  RAM init is the obvious one, and there may be more.

Bullet #1 won't work (which you proved once more).

As you pointed out in your second bullet, hacking up the init code is a multiple day project.  In the same amount of time, you should be up and running out of flash, so why bother (paraphrasing Wolfgang here :-).

If you wish to run out of RAM you are welcome to do so, but about all the advice you will get is "don't do that."

gvb
P.S. Don't do that.  There, I said it first ;-)



******************************************
The information contained in, or attached to, this e-mail, may contain confidential information and is intended solely for the use of the individual or entity to whom they are addressed and may be subject to legal privilege.  If you have received this e-mail in error you should notify the sender immediately by reply e-mail, delete the message from your system and notify your system manager.  Please do not copy it for any purpose, or disclose its contents to any other person.  The views or opinions presented in this e-mail are solely those of the author and do not necessarily represent those of the company.  The recipient should check this e-mail and any attachments for the presence of viruses.  The company accepts no liability for any damage caused, directly or indirectly, by any virus transmitted in this email.
******************************************




More information about the U-Boot mailing list