public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 1/4] ACPI / OSL: Stub out acpi_os_read_pci_configuration when CONFIG_PCI is unset
@ 2018-12-12  5:23 Sinan Kaya
  2018-12-12  5:23 ` [PATCH v4 2/4] ACPI / OSL: Stub out acpi_os_write_pci_configuration " Sinan Kaya
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Sinan Kaya @ 2018-12-12  5:23 UTC (permalink / raw)
  To: linux-acpi; +Cc: Sinan Kaya, Rafael J. Wysocki, Len Brown, open list

Getting ready to allow PCI to be disabled with ACPI enabled. Stub out
acpi_os_read_pci_configuration function that depend on PCI.

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

diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c
index b48874b8e1ea..3e82b50ba811 100644
--- a/drivers/acpi/osl.c
+++ b/drivers/acpi/osl.c
@@ -773,6 +773,7 @@ acpi_status
 acpi_os_read_pci_configuration(struct acpi_pci_id * pci_id, u32 reg,
 			       u64 *value, u32 width)
 {
+#ifdef CONFIG_PCI
 	int result, size;
 	u32 value32;
 
@@ -799,6 +800,9 @@ acpi_os_read_pci_configuration(struct acpi_pci_id * pci_id, u32 reg,
 	*value = value32;
 
 	return (result ? AE_ERROR : AE_OK);
+#else
+	return pr_warn_once("CONFIG_PCI is disabled\n") ? AE_SUPPORT : AE_OK;
+#endif
 }
 
 acpi_status
-- 
2.19.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-12-12  5:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-12-12  5:23 [PATCH v4 1/4] ACPI / OSL: Stub out acpi_os_read_pci_configuration when CONFIG_PCI is unset Sinan Kaya
2018-12-12  5:23 ` [PATCH v4 2/4] ACPI / OSL: Stub out acpi_os_write_pci_configuration " Sinan Kaya
2018-12-12  5:23 ` [PATCH v4 3/4] PCI/ACPI: Allow ACPI to be built without CONFIG_PCI set Sinan Kaya
2018-12-12  5:23 ` [PATCH v4 4/4] ACPI / OSL: Remove PCI bits from ACPICA when CONFIG_PCI is unset Sinan Kaya

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox