firmware: Relocate when load address is not equal to link address
authorAnup Patel <anup.patel@wdc.com>
Fri, 7 Jun 2019 14:56:55 +0000 (20:26 +0530)
committerAnup Patel <anup@brainfault.org>
Wed, 12 Jun 2019 12:26:28 +0000 (17:56 +0530)
commit331f291e4cff8f0b7b35edded21132c2fa69fb97
tree5ee7e81534b7ad7ec44d9f21fdca3bcf9cc3ed6a
parent6fec1c7e1118add3aa16707914ada8adca09bf1b
firmware: Relocate when load address is not equal to link address

This patch extends fw_base to relocate to link address whenever
firmware load address is not equal to link address.

The relocation will not work when load start to load end overlap
link start to link end.

Signed-off-by: Anup Patel <anup.patel@wdc.com>
Tested-by: Lukas Auer <lukas.auer@aisec.fraunhofer.de>
firmware/fw_base.S
firmware/fw_dynamic.elf.ldS
firmware/fw_jump.elf.ldS
firmware/fw_payload.elf.ldS