From 26577d2ecbb8c01635b959d296f70eb251743046 Mon Sep 17 00:00:00 2001 From: Felix Held Date: Fri, 26 Jan 2024 15:05:40 +0100 Subject: soc/amd: factor out acpi_add_fsp_tables Factor out acpi_add_fsp_tables from the soc_acpi_write_tables function and move the remaining parts of the soc_acpi_write_tables function to the SoC's acpi.c. This aligns the other family 17h/19h SoCs more with Genoa and only leaves the FSP-specific code in agesa_acpi.c which will be made common in a following patch. I decided against also renaming agesa_acpi.c to acpi_fsp.c, since that would have made the diff less readable and the files get deleted in a following patch anyway. Signed-off-by: Felix Held Change-Id: Ia87ac0e77c5e673e694703b85a4bab85a34b980e Reviewed-on: https://review.coreboot.org/c/coreboot/+/80224 Tested-by: build bot (Jenkins) Reviewed-by: Matt DeVillier --- src/soc/amd/mendocino/acpi.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/soc/amd/mendocino/acpi.c') diff --git a/src/soc/amd/mendocino/acpi.c b/src/soc/amd/mendocino/acpi.c index 11261db91a..328a2f9b4d 100644 --- a/src/soc/amd/mendocino/acpi.c +++ b/src/soc/amd/mendocino/acpi.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include #include "chip.h" @@ -56,6 +57,19 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->flags |= cfg->common_config.fadt_flags; /* additional board-specific flags */ } +unsigned long soc_acpi_write_tables(const struct device *device, unsigned long current, + acpi_rsdp_t *rsdp) +{ + /* TODO: look into adding CRAT */ + + /* IVRS */ + current = acpi_add_ivrs_table(current, rsdp); + + current = acpi_add_fsp_tables(current, rsdp); + + return current; +} + const acpi_cstate_t cstate_cfg_table[] = { [0] = { .ctype = 1, -- cgit v1.2.3