diff --git a/include/linux/pci-acpi.h b/include/linux/pci-acpi.h index 64dacb7288a6fc79e86ca536753f342a37252949..24c7728ca681f997a3a5b10f78ec7af13fd558d3 100644 --- a/include/linux/pci-acpi.h +++ b/include/linux/pci-acpi.h @@ -41,8 +41,13 @@ static inline acpi_handle acpi_pci_get_bridge_handle(struct pci_bus *pbus) if (pci_is_root_bus(pbus)) dev = pbus->bridge; - else + else { + /* If pbus is a virtual bus, there is no bridge to it */ + if (!pbus->self) + return NULL; + dev = &pbus->self->dev; + } return ACPI_HANDLE(dev); }