firmware: Bring back FW_TEXT_START as an optional parameter

Bring back FW_TEXT_START as an optional parameter to allow users
explicitly specify compile time address for loading debug symbols.
When not specified, the FW_TEXT_START is assumed to be 0.

Fixes: d4d2582eef ("firmware: remove FW_TEXT_START")
Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Tested-by: Clément Léger <cleger@rivosinc.com>
This commit is contained in:
Anup Patel
2024-05-15 09:55:50 +05:30
committed by Anup Patel
parent e3a30a2c91
commit 96f0a2e3ea
6 changed files with 16 additions and 4 deletions

View File

@@ -53,7 +53,9 @@ _try_lottery:
bnez a6, _wait_for_boot_hart
/* relocate the global table content */
lla t2, _fw_start
li t0, FW_TEXT_START /* link start */
lla t1, _fw_start /* load start */
sub t2, t1, t0 /* load offset */
lla t0, __rel_dyn_start
lla t1, __rel_dyn_end
beq t0, t1, _relocate_done