From: Reinhard Meyer Date: Tue, 05 Oct 2010 15:18:48 +0200 Subject: [U-Boot] [RFC] [PATCH V2] arm: arm926ejs: use ELF relocations In-Reply-To: <4CAB1009.60901@free.fr> References: <1286260287-1571-1-git-send-email-albert.aribaud@free.fr> <20101005064516.AEA4C153A7E@gemini.denx.de> <4CAACE47.5090105@emk-elektronik.de> <4CAAD255.1080501@emk-elektronik.de> <4CAAD944.2040309@emk-elektronik.de> <4CAAE2C5.4040304@denx.de> <4CAAE4BF.3030306@free.fr> <4CAAE949.1010200@denx.de> <4CAAEB84.2070602@emk-elektronik.de> <4CAAECA1.8090903@denx.de> <4CAAEDAE.9040908@emk-elektronik.de> <4CAAEFDF.5080803@denx.de> <4CAAF0E3.20801@emk-elektronik.de> <4CAAFEDD.4060005@free.fr> <20101005104041.6A5921539A0@gemini.denx.de> <4CAB0793.4000300@free.fr> <4CAB0957.4070702@emk-elektronik.de> <4CAB1009.60901@free.fr> Message-ID: <4CAB25B8.10207@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 Albert ARIBAUD, > Le 05/10/2010 13:17, Reinhard Meyer a ?crit : >> Dear All ;) >>>> Umm... is my understanding correct that we can drop the whole >>>> CONFIG_SYS_ARM_WITHOUT_RELOC stuff then, too? >>> >>> I believe we're just changing the relocation solution, but we're not >>> changing the overall strategy regarding CONFIG_SYS_ARM_WITHOUT_RELOC. >> >> We should not forget that right now, the "ELF" method uses 8 byte entries >> to relocate, compared to 4 byte entries with the "GOT" method. We >> should not proceed too fast here, the "thought about" tool to squeeze >> down >> the relocation information should not be completely forgotten... >> >> Otherwise even more boards would need to change their mtd partitioning ;) >> >> And I am not too happy if I cannot downgrade to the AT91SAM9XE256 anymore >> (256K NOR) if the 512K version proves difficult to obtain ;) >> >> Reinhard > > I still think a configuration option to choose between relocation > formats would be useful. It could offer: > > - pure ELF format (8 bytes per relocation plus .dynsym) > > ... already there, and then to be done: > > - unified 32-bit format (half the size of pure ELF) > > - unified 16-bit delta format (a fourth of the size of pure ELF) Even an 8-bit delta format is possible: use the value of 0x00 to skip forward 256 addresses, other values to patch.. Assuming that all relocations must be on a 32 bit boundary, the delta values could even be multiplied by 4 :) Best Regards, Reinhard PS: I finished the "C" relocation, but it does not work :( having problems with setting the stack or calling of board_init_r(), I am not sure. Because of otther work I cannot continue there right now. If you want to look at it, I can make a patch.