drivers/usb/acpi: Don't add GPIOs to _CRS for Intel Bluetooth
[coreboot2.git] / src / soc / amd / common / fsp / fsp_memmap.c
blob8bed87b1112791e14cc7c6d4de60b7215725a008
1 /* SPDX-License-Identifier: GPL-2.0-only */
3 #include <amdblocks/memmap.h>
4 #include <console/console.h>
5 #include <fsp/util.h>
6 #include <FspGuids.h>
7 #include <memrange.h>
8 #include <types.h>
10 void fsp_get_smm_region(uintptr_t *start, size_t *size)
12 static uintptr_t smm_start;
13 static size_t smm_size;
15 *start = smm_start;
16 *size = smm_size;
17 if (*size && *start)
18 return;
20 struct range_entry tseg;
22 if (fsp_find_range_hob(&tseg, AMD_FSP_TSEG_HOB_GUID.b) != CB_SUCCESS) {
23 printk(BIOS_ERR, "unable to find TSEG HOB\n");
24 return;
27 smm_start = (uintptr_t)range_entry_base(&tseg);
28 smm_size = range_entry_size(&tseg);
29 *start = smm_start;
30 *size = smm_size;