From mboxrd@z Thu Jan 1 00:00:00 1970 From: Albert ARIBAUD Date: Sat, 02 Oct 2010 09:53:59 +0200 Subject: [U-Boot] ARM relocation, question to Heiko In-Reply-To: <4CA6DC16.5040409@emk-elektronik.de> References: <4CA49746.2050301@emk-elektronik.de> <4CA4AEFF.3050101@denx.de> <20100930174308.070ECD2B48C@gemini.denx.de> <4CA570D3.9040406@denx.de> <4CA57468.6090702@free.fr> <4CA57762.3000201@denx.de> <4CA5821E.3070108@emk-elektronik.de> <4CA5873B.6040907@free.fr> <4CA590E6.6070701@emk-elektronik.de> <4CA59B89.6090207@denx.de> <4CA5BB7A.8050304@emk-elektronik.de> <20101001105506.A64D41539A0@gemini.denx.de> <4CA5BFEF.3090208@emk-elektronik.de> <20101001112125.4076E153A7E@gemini.denx.de> <4CA5C7DE.6010300@emk-elektronik.de> <20101001115908.A34411539A0@gemini.denx.de> <4CA5D26D.2090505@emk-elektronik.de> <4CA5D857.5010009@emk-elektronik.de> <20101001125502.D0B4E1539A0@gemini.denx.de> <4CA6DC16.5040409@emk-elektronik.de> Message-ID: <4CA6E517.9040701@free.fr> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Le 02/10/2010 09:15, Reinhard Meyer a ?crit : > Hello Heiko, > > I try to understand how the relocation process could handle pointers (to > functions or other data) in const or data sections. > Your code cannot know what is data and what is a pointer that needs > adjustment? > > Best Regards, > Reinhard Hi Reinhart, Short answer - the relocation process does not handle pointers inside data structures. And yes, this means the content arrays of pointers such as init_sequence is not relocated. Been there, done that, can give you one of the tee-shirts I got :) ATM I have not found a way to fix this, except making the code which uses the pointers aware that the are location-sensitive and fix them when using them. Amicalement, -- Albert.