[U-Boot] [PATCH 2/5] Added extra documentation about how the relocation address to RAM is picked for ARM.

Wolfgang Denk wd at denx.de
Wed Jul 6 23:29:08 CEST 2011


Dear Christopher Harvey,

In message <20110706205857.GB2168 at harvey-pc.matrox.com> you wrote:
>
> > Also delete "for ARM", and s/arm/<arch>/.  This is not ARM specific.
> 
> I don't understand, I found the following snippet in 
> arch/arm/lib/board.c
> 
>        --addr defined and set here--
> 
> 	gd->relocaddr = addr;
> 	gd->start_addr_sp = addr_sp;
> 	gd->reloc_off = addr - _TEXT_BASE;
> 	debug ("relocation Offset is: %08lx\n", gd->reloc_off);
> 	memcpy (id, (void *)gd, sizeof (gd_t));
> 
> 	relocate_code (addr_sp, id, addr);
> 	/* NOTREACHED - relocate_code() does not return */
> 
> Running grep -R gd->relocaddr *,
> I found similar assignments for various architectures. 

Yes, that's what I said: this is not ARM specific, it is supposed to
be common code used by all architectures (except for the sad fact that
there are several non-conforming implementations).  But if we document
it, we should document the nominal state.  [If in doubt, use the
powerpc implementation as reference.]

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
"It is better to have tried and failed than to have  failed  to  try,
but the result's the same."                           - Mike Dennison


More information about the U-Boot mailing list