diff mbox series

[2/2] PCI: dwc: spear13xx driver needs OF

Message ID 20201001074244.349443-2-thomas.petazzoni@bootlin.com (mailing list archive)
State Accepted, archived
Headers show
Series [1/2] PCI: dwc: armada-8k driver needs OF support | expand

Commit Message

Thomas Petazzoni Oct. 1, 2020, 7:42 a.m. UTC
Fixes the following build warning when CONFIG_OF is disabled:

drivers/pci/controller/dwc/pcie-spear13xx.c:297:34: warning: ‘spear13xx_pcie_of_match’ defined but not used [-Wunused-const-variable=]
  297 | static const struct of_device_id spear13xx_pcie_of_match[] = {
      |                                  ^~~~~~~~~~~~~~~~~~~~~~~

Reported-by: Bjorn Helgaas <helgaas@kernel.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 drivers/pci/controller/dwc/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/pci/controller/dwc/Kconfig b/drivers/pci/controller/dwc/Kconfig
index 96994b715f26..62f6671d7e12 100644
--- a/drivers/pci/controller/dwc/Kconfig
+++ b/drivers/pci/controller/dwc/Kconfig
@@ -96,7 +96,7 @@  config PCI_IMX6
 
 config PCIE_SPEAR13XX
 	bool "STMicroelectronics SPEAr PCIe controller"
-	depends on ARCH_SPEAR13XX || COMPILE_TEST
+	depends on OF && (ARCH_SPEAR13XX || COMPILE_TEST)
 	depends on PCI_MSI_IRQ_DOMAIN
 	select PCIE_DW_HOST
 	help