summaryrefslogtreecommitdiffstats
path: root/pbl
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2012-10-07 19:06:30 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2013-03-07 12:38:01 +0100
commita81ec0225f5a100341c20b4329c8b1d81ab025c4 (patch)
tree0d38efb6ba77f80dc0759513d33ab73f7f9bc868 /pbl
parentb08e08506b9752d3768e42d075283f91d2ed5180 (diff)
downloadbarebox-a81ec0225f5a100341c20b4329c8b1d81ab025c4.tar.gz
ARM: Add relocatable binary support
For making the same binary executable on different SoCs which have different DRAM addresses we have to be independent of the compile time link address. This patch adds relocatable binary support for the ARM architecture. With this two new functions are available. relocate_to_current_adr will fixup the binary to continue executing from the current position. relocate_to_adr will copy the binary to a given address, fixup the binary and continue executing from there. For the PBL and the real image relocatable support can be enabled independently. This is done to (hopefully) better cope with setups where the PBL runs from SRAM or ROM and the real binary does not. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'pbl')
-rw-r--r--pbl/Kconfig10
1 files changed, 10 insertions, 0 deletions
diff --git a/pbl/Kconfig b/pbl/Kconfig
index 39752cc..5c7f62e 100644
--- a/pbl/Kconfig
+++ b/pbl/Kconfig
@@ -18,6 +18,16 @@ config PBL_FORCE_PIGGYDATA_COPY
if PBL_IMAGE
+config PBL_RELOCATABLE
+ depends on ARM
+ bool "relocatable pbl image"
+ help
+ Generate a pbl binary which can relocate itself during startup to run
+ on different addresses. This is useful if your memory layout is not
+ known during compile time.
+ This option only inflluences the PBL image. See RELOCATABLE to also make
+ the real image relocatable.
+
config IMAGE_COMPRESSION
bool
depends on HAVE_IMAGE_COMPRESSION