From 21a8e381ea0dcf650200d2722bf2574958e5c9c7 Mon Sep 17 00:00:00 2001 From: Felix Held Date: Tue, 29 Mar 2022 23:10:45 +0200 Subject: util/amdfwtool: use table-relative addressing in ISH case When the image slot header (ISH) is used, the addresses in the PSP and BIOS directory tables need to be relative to the beginning of the table. Signed-off-by: Felix Held Change-Id: Ia61f7c8313d5a1af95c68b9177a53a2f5443552a Reviewed-on: https://review.coreboot.org/c/coreboot/+/63183 Tested-by: build bot (Jenkins) Reviewed-by: Raul Rangel --- util/amdfwtool/amdfwtool.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'util/amdfwtool') diff --git a/util/amdfwtool/amdfwtool.c b/util/amdfwtool/amdfwtool.c index 0cfe307b2f..9e7f920487 100644 --- a/util/amdfwtool/amdfwtool.c +++ b/util/amdfwtool/amdfwtool.c @@ -1798,7 +1798,9 @@ int main(int argc, char **argv) fprintf(stderr, "WARNING: No SOC name specified.\n"); } - if (amd_romsig->efs_gen.gen == EFS_SECOND_GEN) + if (cb_config.need_ish) + ctx.address_mode = ADDRESS_MODE_2_REL_TAB; + else if (amd_romsig->efs_gen.gen == EFS_SECOND_GEN) ctx.address_mode = ADDRESS_MODE_1_REL_BIOS; else ctx.address_mode = ADDRESS_MODE_0_PHY; -- cgit v1.2.3