soc/intel/skylake/acpi.c: Name devices on secondary bus
Naming a device allows an ACPI _ROM method to be written for it. GPUs may require this to make the configuration data contained within available to an OS driver. This may be required for GPUs that do not contain their vBIOS, or perhaps the drivers require it in this form/fashion. Working on an Acer Aspire VN7-572G (Skylake-U). nouveau successfully obtains the vBIOS via ACPI (kernel 5.7.11). Change-Id: Ida87aebf8fdf341ab350c2bb3704d2ef695cf8f0 Signed-off-by: Benjamin Doron <benjamin.doron00@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/43074 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
This commit is contained in:
parent
6fd87ffe2e
commit
2875df1c9e
|
@ -632,12 +632,18 @@ const char *soc_acpi_name(const struct device *dev)
|
|||
if (dev->path.type != DEVICE_PATH_PCI)
|
||||
return NULL;
|
||||
|
||||
/* Only match devices on the root bus */
|
||||
if (dev->bus && dev->bus->secondary > 0)
|
||||
/* Match functions 0 and 1 for possible GPUs on a secondary bus */
|
||||
if (dev->bus && dev->bus->secondary > 0) {
|
||||
switch (PCI_FUNC(dev->path.pci.devfn)) {
|
||||
case 0: return "DEV0";
|
||||
case 1: return "DEV1";
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
switch (dev->path.pci.devfn) {
|
||||
case SA_DEVFN_ROOT: return "MCHC";
|
||||
case SA_DEVFN_PEG0: return "PEGP";
|
||||
case SA_DEVFN_IGD: return "GFX0";
|
||||
case PCH_DEVFN_ISH: return "ISHB";
|
||||
case PCH_DEVFN_XHCI: return "XHCI";
|
||||
|
|
Loading…
Reference in New Issue