summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorVincent Whitchurch <vincent.whitchurch@axis.com>2023-08-23 12:40:44 +0200
committerRichard Weinberger <richard@nod.at>2023-08-26 22:49:49 +0200
commit974b808d85abbc03c3914af63d60d5816aabf2ca (patch)
tree314858494b094c5f9757ec1685df8b1de90594a2 /arch
parentum: Refactor deprecated strncpy to memcpy (diff)
downloadlinux-974b808d85abbc03c3914af63d60d5816aabf2ca.tar.xz
linux-974b808d85abbc03c3914af63d60d5816aabf2ca.zip
um: virt-pci: fix missing declaration warning
Fix this warning which appears with W=1 and without CONFIG_OF: warning: no previous declaration for 'pcibios_get_phb_of_node' Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202308230949.PphIIlhq-lkp@intel.com/ Fixes: 314a1408b79a ("um: virt-pci: implement pcibios_get_phb_of_node()") Signed-off-by: Vincent Whitchurch <vincent.whitchurch@axis.com> Signed-off-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'arch')
-rw-r--r--arch/um/drivers/virt-pci.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/um/drivers/virt-pci.c b/arch/um/drivers/virt-pci.c
index 7699ca5f35d4..ffe2ee8a0246 100644
--- a/arch/um/drivers/virt-pci.c
+++ b/arch/um/drivers/virt-pci.c
@@ -544,6 +544,7 @@ static void um_pci_irq_vq_cb(struct virtqueue *vq)
}
}
+#ifdef CONFIG_OF
/* Copied from arch/x86/kernel/devicetree.c */
struct device_node *pcibios_get_phb_of_node(struct pci_bus *bus)
{
@@ -562,6 +563,7 @@ struct device_node *pcibios_get_phb_of_node(struct pci_bus *bus)
}
return NULL;
}
+#endif
static int um_pci_init_vqs(struct um_pci_device *dev)
{