[powerpc:next-test 14/40] arch/powerpc/kernel/pci_32.c:233:5: error: no previous prototype for 'pci_device_from_OF_node'
kernel test robot
lkp at intel.com
Fri Feb 3 03:13:02 AEDT 2023
tree: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
head: 9ffcf6a19dbb2a24de2c2d7b2af1e130986cd565
commit: 869363998da87c80c16ff1221e95b41b2d3cceb2 [14/40] powerpc/pci: Allow to disable filling deprecated pci-OF-bus-map
config: powerpc-buildonly-randconfig-r006-20230202 (https://download.01.org/0day-ci/archive/20230203/202302030001.HQPCI490-lkp@intel.com/config)
compiler: powerpc-linux-gcc (GCC) 12.1.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/powerpc/linux.git/commit/?id=869363998da87c80c16ff1221e95b41b2d3cceb2
git remote add powerpc https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git
git fetch --no-tags powerpc next-test
git checkout 869363998da87c80c16ff1221e95b41b2d3cceb2
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=powerpc olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=powerpc SHELL=/bin/bash arch/powerpc/kernel/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp at intel.com>
All errors (new ones prefixed by >>):
>> arch/powerpc/kernel/pci_32.c:233:5: error: no previous prototype for 'pci_device_from_OF_node' [-Werror=missing-prototypes]
233 | int pci_device_from_OF_node(struct device_node *node, u8 *bus, u8 *devfn)
| ^~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/pci_device_from_OF_node +233 arch/powerpc/kernel/pci_32.c
229
230 /*
231 * Returns the PCI device matching a given OF node without pci_to_OF_bus_map
232 */
> 233 int pci_device_from_OF_node(struct device_node *node, u8 *bus, u8 *devfn)
234 {
235 const __be32 *reg;
236 int size;
237
238 /* Check if it might have a chance to be a PCI device */
239 if (!pci_find_hose_for_OF_device(node))
240 return -ENODEV;
241
242 reg = of_get_property(node, "reg", &size);
243 if (!reg || size < 5 * sizeof(u32))
244 return -ENODEV;
245
246 *bus = (be32_to_cpup(®[0]) >> 16) & 0xff;
247 *devfn = (be32_to_cpup(®[0]) >> 8) & 0xff;
248
249 return 0;
250 }
251
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
More information about the Linuxppc-dev
mailing list