blob: payload: Introduce FW_PAYLOAD_OFFSET compile time option

This patch remove hard-coding of payload location in
fw_payload.elf.ldS by adding compile-time option
FW_PAYLOAD_OFFSET.

With the new compile-time option, payload will be placed
at PLAT_TEXT_START + FW_PAYLOAD_OFFSET address.

Signed-off-by: Anup Patel <anup.patel@wdc.com>
This commit is contained in:
Anup Patel 2018-12-19 14:53:26 +05:30 committed by Anup Patel
parent 91fc25f59b
commit fbb4a52330
5 changed files with 7 additions and 1 deletions

View file

@ -14,7 +14,7 @@ SECTIONS
{
#include "fw_common.ldS"
. = ALIGN(0x200000);
. = PLAT_TEXT_START + FW_PAYLOAD_OFFSET;
.payload :
{

View file

@ -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

View file

@ -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

View file

@ -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

View file

@ -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