diff --git a/blob/fw_payload.elf.ldS b/blob/fw_payload.elf.ldS index 2196e9c9..9420f08c 100644 --- a/blob/fw_payload.elf.ldS +++ b/blob/fw_payload.elf.ldS @@ -14,7 +14,7 @@ SECTIONS { #include "fw_common.ldS" - . = ALIGN(0x200000); + . = PLAT_TEXT_START + FW_PAYLOAD_OFFSET; .payload : { diff --git a/blob/objects.mk b/blob/objects.mk index 7376213b..29c2f95c 100644 --- a/blob/objects.mk +++ b/blob/objects.mk @@ -24,6 +24,9 @@ blob-bins-$(FW_PAYLOAD) += fw_payload.bin ifdef FW_PAYLOAD_PATH blob-cppflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_PATH=$(FW_PAYLOAD_PATH) endif +ifdef FW_PAYLOAD_OFFSET +blob-cppflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_OFFSET=$(FW_PAYLOAD_OFFSET) +endif ifdef FW_PAYLOAD_FDT_OFFSET blob-cppflags-$(FW_PAYLOAD) += -DFW_PAYLOAD_FDT_OFFSET=$(FW_PAYLOAD_FDT_OFFSET) endif diff --git a/plat/qemu/sifive_u/config.mk b/plat/qemu/sifive_u/config.mk index ab5d52bd..c856f652 100644 --- a/plat/qemu/sifive_u/config.mk +++ b/plat/qemu/sifive_u/config.mk @@ -28,4 +28,5 @@ FW_JUMP=y FW_JUMP_ADDR=0x80200000 FW_JUMP_FDT_OFFSET=0x2000000 FW_PAYLOAD=y +FW_PAYLOAD_OFFSET=0x200000 FW_PAYLOAD_FDT_OFFSET=0x2000000 diff --git a/plat/qemu/virt/config.mk b/plat/qemu/virt/config.mk index 3e33157f..e922df85 100644 --- a/plat/qemu/virt/config.mk +++ b/plat/qemu/virt/config.mk @@ -28,4 +28,5 @@ FW_JUMP=y FW_JUMP_ADDR=0x80200000 FW_JUMP_FDT_OFFSET=0x2000000 FW_PAYLOAD=y +FW_PAYLOAD_OFFSET=0x200000 FW_PAYLOAD_FDT_OFFSET=0x2000000 diff --git a/plat/sifive/hifive_u540/config.mk b/plat/sifive/hifive_u540/config.mk index fe5e0402..2dc0ac53 100644 --- a/plat/sifive/hifive_u540/config.mk +++ b/plat/sifive/hifive_u540/config.mk @@ -28,4 +28,5 @@ FW_JUMP=y FW_JUMP_ADDR=0x80200000 FW_JUMP_FDT_OFFSET=0x2000000 FW_PAYLOAD=y +FW_PAYLOAD_OFFSET=0x200000 FW_PAYLOAD_FDT_OFFSET=0x2000000