Make PCI reboot conditional on CONFIG_PCI set on the kernel configuration.
Signed-off-by: Sinan Kaya <okaya@kernel.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
#include <linux/acpi.h>
#include <acpi/reboot.h>
+#ifdef CONFIG_PCI
static void acpi_pci_reboot(struct acpi_generic_address *rr, u8 reset_value)
{
unsigned int devfn;
pci_bus_write_config_byte(bus0, devfn,
(rr->address & 0xffff), reset_value);
}
+#else
+static inline void acpi_pci_reboot(struct acpi_generic_address *rr,
+ u8 reset_value)
+{
+ pr_warn_once("PCI configuration space access is not supported\n");
+}
+#endif
void acpi_reboot(void)
{