From: Wolfgang Denk Date: Wed, 16 Jun 2010 14:56:31 +0200 Subject: [U-Boot] Linking some code to internal SRAM instead of SDRAM In-Reply-To: <201006161018.48802.alexander.stein@systec-electronic.com> References: <201006161018.48802.alexander.stein@systec-electronic.com> Message-ID: <20100616125631.972A3D81C69@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 Alexander Stein, In message <201006161018.48802.alexander.stein@systec-electronic.com> you wrote: > > A new approach would be to link lowlevel_init directly at 0x00200000 (which is > AT91SAM9260_SRAM0_BASE) but the code is located next to the "normal" .text > segment. I've prepared a change to cpu/arm926ejs/u-boot.lds (I know it's still > 2010.3 but that shouldn't matter now) which links lowlevel_init to 0x00200000. > I added the symbols __lowlevel_init_start and __lowlevel_init_end to be used > to copy the function from it's LMA to it's VMA address. > I'm rather unsure if this will work as I thought, Of course more has to be > done, like > * Make SRAM address configureable > * Only link to this if CONFIG_SKIP_LOWLEVEL_INIT is not defined > * Maybe create a region for that > * ... > Any opinions, hints, more elegant methods? Who loads the code to SRAM? 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 For every complex problem, there is a solution that is simple, neat, and wrong. - Mark Twain