Re: [PATCH v1] PCI: Set no io resource for bridges that behind VMD controller

From: kernel test robot
Date: Fri Sep 23 2022 - 11:22:27 EST


Hi Xiaochun,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on helgaas-pci/next]
[also build test ERROR on linus/master v6.0-rc6 next-20220923]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url: https://github.com/intel-lab-lkp/linux/commits/Xiaochun-Lee/PCI-Set-no-io-resource-for-bridges-that-behind-VMD-controller/20220913-213745
base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next
config: um-allmodconfig (https://download.01.org/0day-ci/archive/20220924/202209240714.ronvmf1X-lkp@xxxxxxxxx/config)
compiler: gcc-11 (Debian 11.3.0-5) 11.3.0
reproduce (this is a W=1 build):
# https://github.com/intel-lab-lkp/linux/commit/f97a8ba561d7cf5a755c8f42421138e8b1073cf9
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Xiaochun-Lee/PCI-Set-no-io-resource-for-bridges-that-behind-VMD-controller/20220913-213745
git checkout f97a8ba561d7cf5a755c8f42421138e8b1073cf9
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=um SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

drivers/pci/quirks.c: In function 'quirk_vmd_no_iosize':
>> drivers/pci/quirks.c:5985:13: error: implicit declaration of function 'is_vmd' [-Werror=implicit-function-declaration]
5985 | if (is_vmd(bridge->bus) && bridge->is_hotplug_bridge) {
| ^~~~~~
cc1: some warnings being treated as errors


vim +/is_vmd +5985 drivers/pci/quirks.c

5959
5960 #if defined(CONFIG_X86_64) || defined(CONFIG_X86)
5961 /*
5962 * VMD-enabled root ports use Enhanced Configuration Access Mechanism (ECAM)
5963 * access PCI Express configuration space, and offer VMD_CFGBAR as
5964 * base of PCI Express configuration space for the bridges behind it.
5965 * The configuration space includes IO resources, but these IO
5966 * resources are not actually used on X86, especially the NVMes as
5967 * device connnected on this hot plug bridges, and it can result
5968 * in BAR#13 assign IO resource failed. So we clear IO resources
5969 * by setting an IO base value greater than limit to these bridges.
5970 * Hence, append kernel parameter "pci=hpiosize=0KB" can avoid
5971 * this BAR#13 failed messages show out.
5972 */
5973 static void quirk_vmd_no_iosize(struct pci_dev *bridge)
5974 {
5975 u8 io_base_lo, io_limit_lo;
5976 u16 io_low;
5977 u32 io_upper16;
5978 unsigned long io_mask, base, limit;
5979
5980 io_mask = PCI_IO_RANGE_MASK;
5981 if (bridge->io_window_1k)
5982 io_mask = PCI_IO_1K_RANGE_MASK;
5983
5984 /* VMD Domain */
> 5985 if (is_vmd(bridge->bus) && bridge->is_hotplug_bridge) {

--
0-DAY CI Kernel Test Service
https://01.org/lkp