tree:
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git
pci-probe-rework-20210320
head: 0f62dd81d92215e38f654f21e515888fbb2b580c
commit: bd7acd0ea1bf0582ac58af1d1dc87c8cda0c7de1 [21/24] powerpc: rework PCI host
allocation
config: powerpc-mpc834x_itxgp_defconfig (attached as .config)
compiler: powerpc-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
#
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git/commi...
git remote add arnd-playground
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git
git fetch --no-tags arnd-playground pci-probe-rework-20210320
git checkout bd7acd0ea1bf0582ac58af1d1dc87c8cda0c7de1
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
> arch/powerpc/kernel/pci-common.c:1667: warning: expecting
prototype for pci_scan_host_bridge(). Prototype was for pcibios_scan_host_bridge() instead
vim +1667 arch/powerpc/kernel/pci-common.c
98d9f30c820d50 Benjamin Herrenschmidt 2011-04-11 1661
0ed2c722c65051 Grant Likely 2009-08-28 1662 /**
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1663 * pci_scan_host_bridge - Given a
pci_controller, setup and scan the PCI bus
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1664 * @bridge: Pointer to the PCI
host controller instance structure
0ed2c722c65051 Grant Likely 2009-08-28 1665 */
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1666 void
pcibios_scan_host_bridge(struct pci_host_bridge *bridge)
0ed2c722c65051 Grant Likely 2009-08-28 @1667 {
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1668 struct pci_controller *hose =
pci_host_bridge_priv(bridge);
0ed2c722c65051 Grant Likely 2009-08-28 1669 struct device_node *node =
hose->dn;
0ed2c722c65051 Grant Likely 2009-08-28 1670 int mode;
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1671 int error;
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1672
b7c670d673d118 Rob Herring 2017-08-21 1673 pr_debug("PCI: Scanning PHB
%pOF\n", node);
0ed2c722c65051 Grant Likely 2009-08-28 1674
45a709f890a7b8 Bjorn Helgaas 2011-10-28 1675 /* Get some IO space for the new
PHB */
45a709f890a7b8 Bjorn Helgaas 2011-10-28 1676
pcibios_setup_phb_io_space(hose);
45a709f890a7b8 Bjorn Helgaas 2011-10-28 1677
45a709f890a7b8 Bjorn Helgaas 2011-10-28 1678 /* Wire up PHB bus resources */
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1679
pcibios_setup_phb_resources(hose);
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1680
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1681 bridge->sysdata = hose;
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1682 bridge->busnr =
hose->first_busno;
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1683 bridge->custom_bus_scan = 1;
45a709f890a7b8 Bjorn Helgaas 2011-10-28 1684
be8e60d8bed118 Yinghai Lu 2012-05-17 1685 hose->busn.start =
hose->first_busno;
be8e60d8bed118 Yinghai Lu 2012-05-17 1686 hose->busn.end =
hose->last_busno;
be8e60d8bed118 Yinghai Lu 2012-05-17 1687 hose->busn.flags =
IORESOURCE_BUS;
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1688
pci_add_resource(&bridge->windows, &hose->busn);
be8e60d8bed118 Yinghai Lu 2012-05-17 1689
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1690 mode = PCI_PROBE_NORMAL;
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1691 if (node &&
hose->controller_ops.probe_mode)
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1692 mode =
hose->controller_ops.probe_mode(bridge->bus);
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1693 /* Get probe mode and perform
scan */
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1694 pr_debug(" probe mode:
%d\n", mode);
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1695 if (mode == PCI_PROBE_DEVTREE)
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1696 bridge->custom_bus_scan = 1;
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1697
0ed2c722c65051 Grant Likely 2009-08-28 1698 /* Create an empty bus for the
toplevel */
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1699 error =
pci_scan_root_bus_bridge(bridge);
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1700 if (error) {
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1701 pr_err("Failed to create
bus for PCI domain %04x: %d\n",
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1702 hose->global_number,
error);
6905e0abbe6f56 Arnd Bergmann 2020-12-18 1703 pci_free_host_bridge(bridge);
0ed2c722c65051 Grant Likely 2009-08-28 1704 return;
0ed2c722c65051 Grant Likely 2009-08-28 1705 }
0ed2c722c65051 Grant Likely 2009-08-28 1706
be8e60d8bed118 Yinghai Lu 2012-05-17 1707 if (mode == PCI_PROBE_DEVTREE)
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1708 of_scan_bus(node,
bridge->bus);
781fb7a3e4cdca Benjamin Herrenschmidt 2011-09-19 1709
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1710 /* Platform gets a chance to do
some global fixups before
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1711 * we proceed to resource
allocation
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1712 */
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1713 if (ppc_md.pcibios_fixup_phb)
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1714 ppc_md.pcibios_fixup_phb(hose);
491b98c315dbe3 Benjamin Herrenschmidt 2011-11-06 1715
781fb7a3e4cdca Benjamin Herrenschmidt 2011-09-19 1716 /* Configure PCI Express settings
*/
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1717 if (bridge->bus &&
!pci_has_flag(PCI_PROBE_ONLY)) {
781fb7a3e4cdca Benjamin Herrenschmidt 2011-09-19 1718 struct pci_bus *child;
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1719 list_for_each_entry(child,
&bridge->bus->children, node)
a58674ff8383f5 Bjorn Helgaas 2013-08-22 1720
pcie_bus_configure_settings(child);
781fb7a3e4cdca Benjamin Herrenschmidt 2011-09-19 1721 }
0ed2c722c65051 Grant Likely 2009-08-28 1722 }
bd7acd0ea1bf05 Arnd Bergmann 2020-12-19 1723
EXPORT_SYMBOL_GPL(pcibios_scan_host_bridge);
c065488f1acfc0 Kumar Gala 2011-05-19 1724
:::::: The code at line 1667 was first introduced by commit
:::::: 0ed2c722c650513ba4bce868c7a052e576c060e2 powerpc/pci: Merge ppc32 and ppc64
versions of phb_scan()
:::::: TO: Grant Likely <grant.likely(a)secretlab.ca>
:::::: CC: Benjamin Herrenschmidt <benh(a)kernel.crashing.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org