diff options
author | Patrick Rudolph <patrick.rudolph@9elements.com> | 2018-05-15 11:37:26 +0200 |
---|---|---|
committer | Patrick Rudolph <siro@das-labor.org> | 2018-05-17 14:26:53 +0000 |
commit | 5c3452b80032eb81cc458d1fae63089ccc96d95a (patch) | |
tree | 5477069be86ed5fe9af183fcfb5f732518a28404 /src/northbridge/intel/nehalem | |
parent | 735b9a0d1cc4b27647971cff96ad1270200e3cde (diff) | |
download | coreboot-5c3452b80032eb81cc458d1fae63089ccc96d95a.tar.xz |
nb/intel/nehalem: Add ACPI path
Provide a valid ACPI path for coreboot's SSDT generators.
Fixes all ACPI errors found while booting GNU Linux 4.15 on
Lenovo T410.
Change-Id: Idd4986f39f21cb53cb019d0893d40fed94c6505b
Signed-off-by: Patrick Rudolph <siro@das-labor.org>
Reviewed-on: https://review.coreboot.org/26287
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/northbridge/intel/nehalem')
-rw-r--r-- | src/northbridge/intel/nehalem/northbridge.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/northbridge/intel/nehalem/northbridge.c b/src/northbridge/intel/nehalem/northbridge.c index fa5d595c63..0303e92f67 100644 --- a/src/northbridge/intel/nehalem/northbridge.c +++ b/src/northbridge/intel/nehalem/northbridge.c @@ -92,12 +92,33 @@ static void pci_domain_set_resources(struct device *dev) assign_resources(dev->link_list); } +#if IS_ENABLED(CONFIG_HAVE_ACPI_TABLES) +static const char *northbridge_acpi_name(const struct device *dev) +{ + if (dev->path.type == DEVICE_PATH_DOMAIN) + return "PCI0"; + + if (dev->path.type != DEVICE_PATH_PCI || dev->bus->secondary != 0) + return NULL; + + switch (dev->path.pci.devfn) { + case PCI_DEVFN(0, 0): + return "MCHC"; + } + + return NULL; +} +#endif + static struct device_operations pci_domain_ops = { .read_resources = pci_domain_read_resources, .set_resources = pci_domain_set_resources, .enable_resources = NULL, .init = NULL, .scan_bus = pci_domain_scan_bus, +#if IS_ENABLED(CONFIG_HAVE_ACPI_TABLES) + .acpi_name = northbridge_acpi_name, +#endif }; static void mc_read_resources(struct device *dev) |