[U-Boot] [PATCH] arm: Allow u-boot to run from offset base address
Wolfgang Denk
wd at denx.de
Wed Jun 11 06:49:28 CEST 2014
Dear Steve,
In message <53979199.5010100 at broadcom.com> you wrote:
>
> OK - I think that one of the alternate proposals would be to
> conditionally reserve a "32 byte block" prior to the _start symbol (in
> "arch/arm/cpu/armv8/start.S") which would then be filled in by a
> post-processing step... This could be implemented by:
Yes, that illustrates the idea. However, this implementation suffers
from the use of an #ifdef where none is actually needed. Instead, you
can create your own source file which defines the header; this could
be then even in it's own segment, say:
your_header.c:
struct your_header {
u_int32[8];
} your_header __attribute__ ((__section__ (".your_hdr")));
All that is needed then is to make the linker place this segment in
front of the text segment.
This avoids an ugly #ifdef, and also modifications in the common code.
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
Half of the people in the world are below average.
More information about the U-Boot
mailing list