[U-Boot-Users] Bug in malloc()?

Grant Likely grant.likely at secretlab.ca
Mon Oct 29 21:53:12 CET 2007

On 10/29/07, michael.firth at bt.com <michael.firth at bt.com> wrote:
> >
> > Yes, I saw that too with sometimes with the 83xx tree.  Sometimes it
> machine checks, sometimes it goes in an infinite loop.
> This looks like the same issue I'm seeing trying to update my MPC834x
> based system to u-boot-1.3.0-rcx. Under a BDI2000 it seems that several
> of the malloc related pointers have addresses in flash, while in my
> older u-boot version they are correctly pointing to addresses in RAM.
> From this thread, it seems that three fixes have been recommended:
> 1) Disable "CONFIG_RELOC_FIXUP_WORKS" in the CPU header files
> 2) Backout some changes which affect the fixup operations (?)
> 3) Migrate to a newer compiler version

Actually, #3 is migrate to an *older* compiler version.  :-(
Unfortunately EABI relocation seems to be a rather undocumented thing.

If you can use an older compiler, #3 is the easiest workaround.  I use
ELDK 4.1 personally which include GCC 4.0.0.  You can backout the
enabling of CONFIG_RELOC_FIXUP_WORKS for 82xx, but I don't want to
apply that change to mainline if at all possible.  I'd rather get
relocation working properly for all compilers once and for all.

> Which of these three options is the best to take, or has this thread not
> yet reached that conclusion?
> Thanks
> Michael

Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
grant.likely at secretlab.ca
(403) 399-0195

More information about the U-Boot mailing list