[U-Boot] U-Boot proper(not SPL) relocate option

Wolfgang Denk wd at denx.de
Mon Nov 27 13:21:11 UTC 2017


Dear Masahiro,

In message <CAK7LNARc-MUPRmHSiSjtea9X6hpRAe9t9wgdbdfg2DYSEpC4RA at mail.gmail.com> you wrote:
>
> When we talk about "relocation", two things are happening.
> 
>  [1] U-Boot proper copies itself to the very end of DRAM

...to the very end of DRAM minus space reserved for any memory
regions we want to reserver for / share with the Linux kernel
(video memory, log buffer, protected RAM, ...)

>  [2] Fix-up the global symbols
> 
> In my opinion, only [2] is useful.

This is your opinion, accepted.
I do not agree with this, i. e. I have a different opinion.

> SPL initializes the DRAM, so it knows the base and size of DRAM.

But it does not know the relocation address yet.  As this is
dynamically computed, depending on environment variable settings,
moving this calculation into the SPL means the SPL must be capable to
read the environment.  this pulls in a ton of code, and any
advantages you may have for falcon mode are damaged.

> The following is how the ideal boot loader would work.
> 
> 
> Requirement for U-Boot proper:
> U-Boot never changes the location by itself.

This means you kill all the features that depend on this?

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
f u cn rd ths, itn tyg h myxbl cd.


More information about the U-Boot mailing list