]> www.infradead.org Git - linux.git/commitdiff
MIPS: lantiq: Fix pcibios_plat_dev_init() "no previous prototype" warning
authorBjorn Helgaas <bhelgaas@google.com>
Tue, 10 Oct 2023 14:34:05 +0000 (09:34 -0500)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Thu, 19 Oct 2023 08:25:49 +0000 (10:25 +0200)
After bbd8810d3998 ("PCI: Remove unused includes and superfluous struct
declaration"), <linux/of_pci.h> no longer includes <linux/pci.h>, which
provides the extern declarations for pcibios_plat_dev_init() and
pcibios_map_irq() via <asm/pci.h>.

This results in these new warnings:

  arch/mips/pci/fixup-lantiq.c:13:5: warning: no previous prototype for 'pcibios_plat_dev_init' [-Wmissing-prototypes]
  arch/mips/pci/fixup-lantiq.c:24:5: warning: no previous prototype for 'pcibios_map_irq' [-Wmissing-prototypes]

Include <linux/pci.h> directly to get these declarations.

Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202310070445.tzRBNYRC-lkp@intel.com/
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/pci/fixup-lantiq.c

index 105569c1b7127b6a03bb76abf812908d486e0160..8f5fb98b3984ec39f42c9e7f9756036fd37eddfe 100644 (file)
@@ -6,6 +6,7 @@
 
 #include <linux/of_irq.h>
 #include <linux/of_pci.h>
+#include <linux/pci.h>
 
 int (*ltq_pci_plat_arch_init)(struct pci_dev *dev) = NULL;
 int (*ltq_pci_plat_dev_init)(struct pci_dev *dev) = NULL;