[U-Boot] [PATCH v3] Switch from archive libraries to partial linking

Wolfgang Denk
2010-11-19T12:55:34Z

Dear Sebastien Carlier,

In message <sebastien.carlier@9400084bb093b10e93ff65be513a8043def9b8e1> you wrote:
>
> Is it not possible to tell the linker to place a made-up 32 kB symbol
> within the text section at address 0x40008000? I am not familiar enough
> with ld to tell whether there are restrictions for setting the absolute
> address of a symbol that would disallow it in this case.

I don't know such a method. We would not even have to make up any
symbols - if we could forst the Linker to place "environment" at
0x40008000 and "redundand_environment" at 0x4000c000 everything would
be perfect. Before this patch, this was what we had:

...
0x40005ebc inflateInit2_
0x400058f4 inflate_table
arch/powerpc/lib/cache.o(.text)
.text 0x40007c20 0x64 arch/powerpc/lib/cache.o
0x40007c20 flush_cache
0x00008000 . = DEFINED (env_offset)?env_offset:.
*fill* 0x40007c84 0x37c 00
common/env_embedded.o(.ppcenv)
.ppcenv 0x40008000 0x8000 common/env_embedded.o
0x40008000 environment
0x4000c000 redundand_environment
*(.text)
.text 0x40010000 0x4 common/env_embedded.o
0x40010000 env_size
.text 0x40010004 0x0 lib/libgeneric.a(ctype.o)
.text 0x40010004 0x10c lib/libgeneric.a(div64.o)
0x40010004 __div64_32
...

But I don't know of a way to enforce this...

Best regards,

Wolfgang Denk

--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
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
Every little picofarad has a nanohenry all its own. - Don Vonada