[U-Boot-Users] code relocation and symbolic debugging
vb
vb at vsbe.com
Tue Mar 20 02:52:29 CET 2007
Wolfgang, thank you again for a prompt reply, please see below:
On 3/19/07, Wolfgang Denk <wd at denx.de> wrote:
>
> If you want to be able to erase / progarm the flash, at least youyr
> flash driver must be running from non-flash memory (at leats on most
> standard flash chips). If you want to be able to update U-Boot in
> flash you must have all of U-Boot running in some other memory.
>
> This requires to copy & relocate the image.
>
> And this has nothing to do with where the code/data segments are
> placed.
>
of course, no doubt relocation is required both for reasons you
mention, as well as to improve performance, etc. I was asking about
using position independent code/data, recalculating addresses, etc.
> > Utilizing this feature would allow to benefit from all the u-boot
> > early startup elegant smarts (running with data in the cache, testing
> > the entire dram, stc)., then the first stage code would just move the
> > main chunk to the predefined location and pass control to it. This way
> > no need to worry about adjusting tabled addresses, about data not
> > fitting into the room allotted, about gdb not alllowing to see
> > variables - this approach is pretty much worry free at least on mips
> > and ppc architectures where I extensively deployed it before joining
> > the u-boot club.
>
> Feel free to submit patches - if they actually work we will be happy
> to consider them.
>
> I'm just afraid that you miss a few points...
>
> > Of course with such a heavy legacy like u-boot has it is difficult to
> > switch on a whim, but would this be even considered? And why has not
> > it been done like that in the first place?
>
well, I am sure I can make it work for PPC and I can test it because I
am working on a PPC board right now, would you allow introducing this
different approach just on PPC to start with?
cheers,
/vb
> Because nobody was clever enough to implement it? Or maybe because it
> does not work? Dunno...
>
> Best regards,
>
> Wolfgang Denk
>
> --
> DENX Software Engineering GmbH, HRB 165235 Munich, CEO: Wolfgang Denk
> Office: Kirchenstr. 5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
> "Text processing has made it possible to right-justify any idea, even
> one which cannot be justified on any other grounds."
> -- J. Finnegan, USC.
>
More information about the U-Boot
mailing list