From: Reinhard Meyer Date: Fri, 01 Oct 2010 12:44:10 +0200 Subject: [U-Boot] ARM relocation, probably trivial mistake - back to original problem In-Reply-To: <4CA59B89.6090207@denx.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> Message-ID: <4CA5BB7A.8050304@emk-elektronik.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 Heiko Schocher, > Hmm.. mabe something with at91_clock_init() > > This is called in arch_cpu_init(), and > at the end, clocks are stored in > > arch/arm/cpu/arm926ejs/at91/clock.c > > in "static unsigned long" vars ... as this code > runs before relocation, this seems to me as it > could be the reason for your problems ... but I > can;t try it here ... can you check this? Indeed, that is called before relocation, because the clock frequencies are needed by almost all drivers, including the timer. I am unsure now how to fix this. I see two options: 1. calculate afresh every time a get_*_clk_rate() is called - thus not needing static storage 2. store the values in bd->something (if it's permissible to expand bd) Reinhard