From f85f7d7aed975e0ae3d06fc4a24384ab2ddecabd Mon Sep 17 00:00:00 2001 From: Jincheng Li Date: Thu, 15 May 2025 10:22:46 +0800 Subject: [PATCH] mb/intel/beechnutcity_crb: Use host address for BiosRegionBase FMAP_SECTION_SI_BIOS_START is used to pass host address for UPD BiosRegionBase. It changes to flash address after: commit 2efe4df5227a ("treewide: Assume FMAP_SECTION_FLASH_START = 0") Convert FMAP_SECTION_SI_BIOS_START to host address to set BiosRegionBase. TESTED=Build and boot on intel/beechnutcity CRB, check boot log with: [INFO ] BiosRegionBase is set to ff000000 [INFO ] BiosRegionSize is set to 1000000 Change-Id: Ie115bd8e9044455185f82885a306849c509157bb Signed-off-by: Jincheng Li Reviewed-on: https://review.coreboot.org/c/coreboot/+/87690 Reviewed-by: Matt DeVillier Tested-by: build bot (Jenkins) --- src/mainboard/intel/beechnutcity_crb/romstage.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mainboard/intel/beechnutcity_crb/romstage.c b/src/mainboard/intel/beechnutcity_crb/romstage.c index ef91b39f93..a77819955c 100644 --- a/src/mainboard/intel/beechnutcity_crb/romstage.c +++ b/src/mainboard/intel/beechnutcity_crb/romstage.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include "chip.h" @@ -32,7 +33,10 @@ void mainboard_memory_init_params(FSPM_UPD *mupd) CONFIG_BMC_KCS_BASE); /* Set BIOS regeion UPD, otherwise MTRR might set incorrectly during TempRamExit API */ - m_cfg->BiosRegionBase = FMAP_SECTION_SI_BIOS_START; + struct flash_mmap_window table; + spi_flash_get_mmap_windows(&table); + + m_cfg->BiosRegionBase = table.host_base + FMAP_SECTION_SI_BIOS_START; m_cfg->BiosRegionSize = FMAP_SECTION_SI_BIOS_SIZE; printk(BIOS_INFO, "BiosRegionBase is set to %x\n", mupd->FspmConfig.BiosRegionBase); printk(BIOS_INFO, "BiosRegionSize is set to %x\n", mupd->FspmConfig.BiosRegionSize);