[U-Boot] v2010-rc2: OMAP3 broken
Heiko Schocher
hs at denx.de
Mon Nov 29 18:22:51 CET 2010
Hello Albert,
Albert ARIBAUD wrote:
> Le 29/11/2010 16:04, Heiko Schocher a écrit :
>> Hello Albert,
>>
>> Albert ARIBAUD wrote:
>>> I'll take a look this evening at builds with and without the SORT() from
>>> an ELF relocation tables perspective.
>>
>> I debugged on the beagle board a little bit in this problem, and here
>> what I found:
[...]
>> Why is the rel.dyn Section in the bss section?
>>
> The .rel.dyn section is not "in" or "out" of the BSS: they are
> overlapped, i.e. they should start at the same address.
>
> As indicated in the documentation, BSS should never be used before
> relocation; it actually *cannot* be written into by boards which start
> from NOR, and is set to zero for all boards right after relocation.
Yep.
> Since BSS does not exist before relocation, and .rel.dyn does not exist
> after relocation, they can use the same location: overlaying them is the
> best approach in order to get the smallest binary in Flash *and* the
> smallest image in RAM.
Ah, thats what I missed, thanks!
> We can add code to try and catch the most obvious corruption of the
> relocation tables due to BSS being accessed before relocation, but we
> can't be sure to catch them all. The real solution is to fix the BSS usage.
Yep.
bye,
Heiko
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
More information about the U-Boot
mailing list