lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20181219224659.4802-3-okaya@kernel.org>
Date:   Wed, 19 Dec 2018 22:46:54 +0000
From:   Sinan Kaya <okaya@...nel.org>
To:     linux-acpi@...r.kernel.org
Cc:     Sinan Kaya <okaya@...nel.org>,
        "Rafael J. Wysocki" <rjw@...ysocki.net>,
        Len Brown <lenb@...nel.org>,
        linux-kernel@...r.kernel.org (open list)
Subject: [PATCH v12 2/7] ACPI: Allow CONFIG_PCI to be unset for reboot

Make PCI reboot conditional on CONFIG_PCI set on the kernel configuration.

Signed-off-by: Sinan Kaya <okaya@...nel.org>
---
 drivers/acpi/reboot.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/acpi/reboot.c b/drivers/acpi/reboot.c
index d642a9dede52..ca707f5b521d 100644
--- a/drivers/acpi/reboot.c
+++ b/drivers/acpi/reboot.c
@@ -4,6 +4,7 @@
 #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;
@@ -21,6 +22,13 @@ static void acpi_pci_reboot(struct acpi_generic_address *rr, u8 reset_value)
 	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)
 {
-- 
2.19.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ