From 5d32a66541c4683456507481a0944ed2985e75c7 Mon Sep 17 00:00:00 2001 From: Sinan Kaya Date: Wed, 19 Dec 2018 22:46:56 +0000 Subject: PCI/ACPI: Allow ACPI to be built without CONFIG_PCI set We are compiling PCI code today for systems with ACPI and no PCI device present. Remove the useless code and reduce the tight dependency. Signed-off-by: Sinan Kaya Acked-by: Bjorn Helgaas # PCI parts Acked-by: Ingo Molnar Signed-off-by: Rafael J. Wysocki --- include/acpi/acpi_drivers.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/acpi/acpi_drivers.h') diff --git a/include/acpi/acpi_drivers.h b/include/acpi/acpi_drivers.h index 14499757338f..de1804aeaf69 100644 --- a/include/acpi/acpi_drivers.h +++ b/include/acpi/acpi_drivers.h @@ -88,7 +88,14 @@ int acpi_pci_link_free_irq(acpi_handle handle); struct pci_bus; +#ifdef CONFIG_PCI struct pci_dev *acpi_get_pci_dev(acpi_handle); +#else +static inline struct pci_dev *acpi_get_pci_dev(acpi_handle handle) +{ + return NULL; +} +#endif /* Arch-defined function to add a bus to the system */ -- cgit