soc/intel/xeon_sp: Create SSDT for Gen6 LPC controller
In coreboot, LPC ACPI objects with its attached devices are usually provided by static DSDT. For Xeon-SP Gen6 LPC, its logical attached devices are created from dynamic SSDT (e.g. super IO). Create a simple SSDT for LPC in dynamic way as well to complete the device relationship chain. Fix below issues during Linux OS boot. The issue will block Windows OS boot as well. [ 22.986142] ACPI BIOS Error (bug): Could not resolve symbol [\_SB.DI00.LPCB], AE_NOT_FOUND (20230628/dswload2-162) [ 22.986792] ACPI Error: AE_NOT_FOUND, During name lookup/catalog (20230628/psobject-220) [ 22.987786] ACPI: Skipping parse of AML opcode: Scope (0x0010) Change-Id: I08543fc77f0f3e633b05889e921c5183e6e20d8e Signed-off-by: Lu, Pen-ChunX <pen-chunx.lu@intel.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/84842 Reviewed-by: Martin L Roth <gaumless@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
9c7ce22de9
commit
bc1e422665
3 changed files with 37 additions and 0 deletions
|
|
@ -53,6 +53,9 @@ void lpc_open_mmio_window(uintptr_t base, size_t size);
|
|||
/* Init SoC Specific LPC features. Common definition will be weak and
|
||||
each soc will need to define the init. */
|
||||
void lpc_soc_init(struct device *dev);
|
||||
/* Create SoC specific SSDT, by default it does nothing so that static
|
||||
DSDT could be used. */
|
||||
void lpc_soc_fill_ssdt(const struct device *dev);
|
||||
/* Fill up LPC IO resource structure inside SoC directory */
|
||||
void pch_lpc_soc_fill_io_resources(struct device *dev);
|
||||
/* Set LPC BIOS Control BILD bit. */
|
||||
|
|
|
|||
|
|
@ -16,6 +16,15 @@ __weak void lpc_soc_init(struct device *dev)
|
|||
/* no-op */
|
||||
}
|
||||
|
||||
/* Create SoC specific SSDT */
|
||||
__weak void lpc_soc_fill_ssdt(const struct device *dev)
|
||||
{
|
||||
/*
|
||||
* no-op
|
||||
* by default it does nothing so that static DSDT could be used
|
||||
*/
|
||||
}
|
||||
|
||||
/* Fill up LPC IO resource structure inside SoC directory */
|
||||
__weak void pch_lpc_soc_fill_io_resources(struct device *dev)
|
||||
{
|
||||
|
|
@ -134,6 +143,7 @@ struct device_operations lpc_ops = {
|
|||
#if CONFIG(HAVE_ACPI_TABLES)
|
||||
.write_acpi_tables = southbridge_write_acpi_tables,
|
||||
.acpi_name = lpc_acpi_name,
|
||||
.acpi_fill_ssdt = lpc_soc_fill_ssdt,
|
||||
#endif
|
||||
.init = lpc_soc_init,
|
||||
.scan_bus = scan_static_bus,
|
||||
|
|
|
|||
|
|
@ -6,6 +6,30 @@
|
|||
#include <intelblocks/pcr.h>
|
||||
#include <soc/pcr_ids.h>
|
||||
|
||||
#include <acpi/acpigen.h>
|
||||
#include <acpi/acpigen_pci.h>
|
||||
|
||||
void lpc_soc_fill_ssdt(const struct device *dev)
|
||||
{
|
||||
const char *scope = acpi_device_scope(dev);
|
||||
const char *name = acpi_device_name(dev);
|
||||
|
||||
if (!scope || !name) {
|
||||
printk(BIOS_ERR, "%s: Missing ACPI path/scope\n", dev_path(dev));
|
||||
return;
|
||||
}
|
||||
|
||||
/* Device */
|
||||
acpigen_write_scope(scope);
|
||||
acpigen_write_device(name);
|
||||
|
||||
printk(BIOS_DEBUG, "%s.%s: %s\n", scope, name, dev_path(dev));
|
||||
acpigen_write_ADR_pci_device(dev);
|
||||
|
||||
acpigen_write_device_end(); /* Device */
|
||||
acpigen_write_scope_end(); /* Scope */
|
||||
}
|
||||
|
||||
void lpc_soc_init(struct device *dev)
|
||||
{
|
||||
printk(BIOS_SPEW, "pch: lpc_init\n");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue