From: arun c Date: Fri, 10 Aug 2007 12:41:53 +0530 Subject: [U-Boot-Users] ppc4xx relocate_code what it does???? In-Reply-To: <20070810161257.GJ11316@GNU> References: <20070810161257.GJ11316@GNU> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi all, I just want to disable relocation because i want to run the uboot from ram and debug(BDI 2000). I tried like this i changed the TEXT_BASE to 0x1900000 (my ram is 32 Mb) But my u-boot code is failing to compile (I am using ELDK) please anybody help me Best Regards, Arun On 8/10/07, urwithsughosh at gmail.com wrote: > > Hi, > > > > > After doing all the initializations (i.e) serail_init,init_baudrate > > etc.., finally it reaches to relocate_code(addr_sp,id,addr) in the > > board_init_f() function in the board.c file (lib_ppc\board.c) ppc4xx. > > what it does? which part > > of the code or data copies from flash to the ram? > > The whole u-boot image is copied from the flash to the ram.This is > done after the board_init_f function initialises all the required > controllers.The relocation code is present in cpu//start.S > > > > Is this required while I am running from the SDRAM? what part of the > > code I can skip in the relocate_code function? If running from the > > flash what should i do? > > It is required to run from the SDRAM.Since the entire image > is copied as is, the complete code needs to be copied.Why would you > want to tamper with it? > > -- > sughosh >