summaryrefslogtreecommitdiff
path: root/src/soc/intel/xeon_sp/cpx
diff options
context:
space:
mode:
authorJonathan Zhang <jonzhang@fb.com>2020-07-09 17:44:18 -0700
committerAngel Pons <th3fanbus@gmail.com>2020-07-23 08:46:14 +0000
commitb45ed65ef01278685abca80cd8f23c14e6e54581 (patch)
tree41ba6ed8f48b245e91f9f2f405cbadc7cf2c4c50 /src/soc/intel/xeon_sp/cpx
parentb086728094d70b3455ddc66c513571e319516efe (diff)
soc/intel/xeon_sp/cpx: display SystemMemoryMapHob fields
SystemMemoryMapHob is necessary for SMBIOS type 17 among other things. It is a fairly large structure, so the pointer to the data instead of the structure itself, is included in the HOB. Use pointer to SystemMemoryMapHob structure to interpret SystemMemoryHob HOB body. Adjust the structure definition to match with CPX-SP ww28 release. Display more fields to ensure the structure definition is correct. TEST=Boot DeltaLake server, and check field values of SystemMemoryMapHob to make sure they are correct: 0x7590a090, 0x00000020 bytes: HOB_TYPE_GUID_EXTENSION f8870015-6994-4b98-95a2bd56da91c07f: FSP_SYSTEM_MEMORYMAP_HOB_GUID ================== MEMORY MAP HOB DATA ================== hob: 0x777f7000, structure size: 0x6c88 lowMemBase: 0x0, lowMemSize: 0x20, highMemBase: 0x40, highMemSize: 0x5d0 memSize: 0x600, memFreq: 0xb76 NumChPerMC: 3 SystemMemoryMapElement Entries: 2, entry size: 16 memory_map 0 BaseAddress: 0x0, ElementSize: 0x20, Type: 0x1 memory_map 1 BaseAddress: 0x40, ElementSize: 0x5d0, Type: 0x1 BiosFisVersion: 0x0 MmiohBase: 0x80000 0x777f7000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ ... Signed-off-by: Jonathan Zhang <jonzhang@fb.com> Change-Id: I271bcbd6030276b8fcd99d5b4f2c93f034dd9b52 Reviewed-on: https://review.coreboot.org/c/coreboot/+/43336 Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com> Reviewed-by: Angel Pons <th3fanbus@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/intel/xeon_sp/cpx')
-rw-r--r--src/soc/intel/xeon_sp/cpx/hob_display.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/soc/intel/xeon_sp/cpx/hob_display.c b/src/soc/intel/xeon_sp/cpx/hob_display.c
index 0263472fc0..3d61a8209c 100644
--- a/src/soc/intel/xeon_sp/cpx/hob_display.c
+++ b/src/soc/intel/xeon_sp/cpx/hob_display.c
@@ -33,9 +33,9 @@ const char *soc_get_guid_name(const uint8_t *guid)
return NULL;
}
-static void soc_display_memmap_hob(const struct SystemMemoryMapHob *hob_addr)
+static void soc_display_memmap_hob(const struct SystemMemoryMapHob **hob_addr)
{
- struct SystemMemoryMapHob *hob = (struct SystemMemoryMapHob *)hob_addr;
+ struct SystemMemoryMapHob *hob = (struct SystemMemoryMapHob *)*hob_addr;
printk(BIOS_DEBUG, "================== MEMORY MAP HOB DATA ==================\n");
printk(BIOS_DEBUG, "hob: %p, structure size: 0x%lx\n",
@@ -47,6 +47,7 @@ static void soc_display_memmap_hob(const struct SystemMemoryMapHob *hob_addr)
printk(BIOS_DEBUG, "\tmemSize: 0x%x, memFreq: 0x%x\n",
hob->memSize, hob->memFreq);
+ printk(BIOS_DEBUG, "\tNumChPerMC: %d\n", hob->NumChPerMC);
printk(BIOS_DEBUG, "\tSystemMemoryMapElement Entries: %d, entry size: %ld\n",
hob->numberEntries, sizeof(SYSTEM_MEMORY_MAP_ELEMENT));
for (int e = 0; e < hob->numberEntries; ++e) {
@@ -56,6 +57,9 @@ static void soc_display_memmap_hob(const struct SystemMemoryMapHob *hob_addr)
mem_element->ElementSize, mem_element->Type);
}
+ printk(BIOS_DEBUG, "\tBiosFisVersion: 0x%x\n", hob->BiosFisVersion);
+ printk(BIOS_DEBUG, "\tMmiohBase: 0x%x\n", hob->MmiohBase);
+
hexdump(hob, sizeof(*hob));
}
@@ -181,5 +185,5 @@ void soc_display_hob(const struct hob_header *hob)
if (fsp_guid_compare(guid, fsp_hob_iio_uds_guid))
soc_display_iio_universal_data_hob((const IIO_UDS *)(guid + 16));
else if (fsp_guid_compare(guid, fsp_hob_memmap_guid))
- soc_display_memmap_hob((const struct SystemMemoryMapHob *)(guid + 16));
+ soc_display_memmap_hob((const struct SystemMemoryMapHob **)(guid + 16));
}