From: Wolfgang Denk Date: Sat, 03 Oct 2009 16:28:23 +0200 Subject: [U-Boot] [PATCH] relocation: Do not relocate NULL pointers. In-Reply-To: <1254577553.23101.14.camel@ptyser-laptop> References: <1253706706-30364-1-git-send-email-Joakim.Tjernlund@transmode.se> <1253710639.3968.19.camel@ptyser-laptop> <20090923182314.1B317832E864@gemini.denx.de> <1254112288.6589.15.camel@ptyser-laptop> <1254141946.10493.11.camel@ptyser-laptop> <1254150538.24140.2478.camel@localhost.localdomain> <20091003081345.9CFBF832E408@gemini.denx.de> <20091003121357.20A3C832E408@gemini.denx.de> <1254577553.23101.14.camel@ptyser-laptop> Message-ID: <20091003142823.F037D832E408@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Peter, In message <1254577553.23101.14.camel@ptyser-laptop> you wrote: > > > So how should we proceed? My plan was to merge the "reloc" branch by > > the end of next week. Is this still realistic? > > That plan is realistic. The executive summary is: > The current "reloc" branch works, and is an improvement on U-Boot's > previous "semi-reolcation", so we should merge it for this release. OK, so let's do that. > There are a few change which would further improve relocation that Jocke > and I want to get merged. Whether these improvements occur in this > release or the next is not a big deal to me. > 1. Fix relocation of NULL pointers. > eg the following code would print the relocation fixup offset instead of > the expected NULL. > void weak_fun(void) __attribute__((weak)); > printf("weak_fun:%p\n", weak_fun); > This was already an issue, so we're not breaking anything in the "reloc" > branch > > 2. Move relocation fixup code to C-code > > 3. Possibly get true relocation working so that U-Boot could be located > anywhere and still execute. I tend to get all of this (as far as it's available and considered to be ready) into this release, so we have it all in one big block. > Jocke has 1 and 2 mostly figured out, I just need some time to play with > the linker scripts a bit more to ensure nothing breaks. (Sorry Jocke, > its been a busy week). You don't have to apologize. We've all been in similar situations before. And we really appreciate your efforts (and Jocke's, of course). 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 Q: Why do mountain climbers rope themselves together? A: To prevent the sensible ones from going home.