Martin Roth | f95a11e | 2022-10-21 16:43:08 -0600 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
| 2 | |
| 3 | /* TODO: Make common? */ |
| 4 | |
| 5 | #include <acpi/acpi.h> |
| 6 | #include <amdblocks/acpi.h> |
| 7 | #include <device/device.h> |
| 8 | #include <FspGuids.h> |
| 9 | #include <soc/acpi.h> |
| 10 | #include <types.h> |
| 11 | |
Felix Held | ae54db7 | 2024-01-26 14:14:21 +0100 | [diff] [blame^] | 12 | unsigned long soc_acpi_write_tables(const struct device *device, unsigned long current, |
| 13 | acpi_rsdp_t *rsdp) |
Martin Roth | f95a11e | 2022-10-21 16:43:08 -0600 | [diff] [blame] | 14 | { |
Felix Held | 5c56b16 | 2023-01-17 02:52:03 +0100 | [diff] [blame] | 15 | /* TODO: look into adding CRAT */ |
| 16 | |
Martin Roth | f95a11e | 2022-10-21 16:43:08 -0600 | [diff] [blame] | 17 | /* add ALIB SSDT from HOB */ |
Felix Held | 4235fb6 | 2023-01-17 02:51:11 +0100 | [diff] [blame] | 18 | current = acpi_align_current(current); |
Martin Roth | f95a11e | 2022-10-21 16:43:08 -0600 | [diff] [blame] | 19 | current = add_agesa_fsp_acpi_table(AMD_FSP_ACPI_ALIB_HOB_GUID, "ALIB", rsdp, current); |
| 20 | |
| 21 | /* IVRS */ |
Felix Held | a4a2a4f | 2024-01-25 18:53:54 +0100 | [diff] [blame] | 22 | current = acpi_add_ivrs_table(current, rsdp); |
Martin Roth | f95a11e | 2022-10-21 16:43:08 -0600 | [diff] [blame] | 23 | |
| 24 | return current; |
| 25 | } |