[U-Boot] ELF_RELOC causes strange I-cache issues

Albert ARIBAUD albert.aribaud at free.fr
Fri Oct 22 15:19:08 CEST 2010


Le 22/10/2010 14:26, Wolfgang Denk a écrit :

> I think we halve solved (wel, actually worked around) the problem; the
> solution is (like so often) adding / increasing a delay in the USB
> code.

Good! Out of curiosity, is this timing inevitable or is there a way to 
turn it into a wait loop (plus a timeout for security)?

> I think the ELF relocations only triggered the problem because they
> resulted in smaller code which (most probably) also executes a bit
> faster - and the difference was enough to trigger the problem.

I concur for the execution speed, but not due to ELF relocations per se, 
rather due to the i-cache being turned on and working correctly, i.e. 
increasing code speed, to the point that a bad timing condition occurs.

As for size, ELF relocations actually do not change executable code size 
with respect to "fixed" relocation. GOT relocation, OTOH, would increase 
the code size and slow it slightly down.

We'll probably see more of these with the increased use of i-cache and 
d-cache on ARM.

> Best regards,
>
> Wolfgang Denk

Amicalement,
-- 
Albert.


More information about the U-Boot mailing list