[U-Boot] ARM relocation, question to Heiko

Albert ARIBAUD albert.aribaud at free.fr
Sun Oct 3 20:34:41 CEST 2010


Le 03/10/2010 20:03, Wolfgang Denk a écrit :

> Dear Reinhard Meyer,
>
> In message<4CA6E8E5.2090605 at emk-elektronik.de>  you wrote:
>>
>>> And yes, this means the content arrays of pointers such as init_sequence
>>> is not relocated. Been there, done that, can give you one of the
>>> tee-shirts I got :)
>
> It should work.
>
> Eventually we need to find out which sort of tweaking of compiler
> and/or linker options is needed on ARM.

While looking for enhancements to Heiko's arm relocation patches, I have 
gone through all relocation related compiler and linker options, and 
then some. -fPIC / -fPIE will not generate GOT fixups for data 
containing pointers, and I have found no additional option that will.

OTOH, -pie will generate this kind of fixup (and all others needed) in 
the form of .rel.dyn relocations, as Bill describes.

> Well, please keep in mind that all this code is working find on
> PowerPC, which has been using relocation right from the beginning.

I don't mean to say that PPC relocation does not work;  I mean to say 
that a mechanism intended for one architecture may not be the optimal 
one for another, and if two mechanisms exist which provide relocation 
and one of them does not require specific tricks in the code, then I 
would choose this one.

> Best regards,
>
> Wolfgang Denk

Amicalement,
-- 
Albert.


More information about the U-Boot mailing list