Hi Jon, [FYI, it's a private test report for your RFC patch.] [auto build test WARNING on pci/next] [also build test WARNING on iommu/next tip/x86/core v5.5-rc4 next-20191220] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Jon-Derrick/Clean-up-VMD-DMA-Map-Ops/20200103-175834 base: https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git next config: x86_64-randconfig-f001-20200103 (attached as .config) compiler: gcc-7 (Debian 7.5.0-3) 7.5.0 reproduce: # save the attached .config to linux build tree make ARCH=x86_64 If you fix the issue, kindly add following tag Reported-by: kbuild test robot All warnings (new ones prefixed by >>): In file included from arch/x86/include/asm/percpu.h:45:0, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from arch/x86/pci/common.c:8: arch/x86/pci/common.c: In function 'set_dev_domain_options': arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/kernel.h:995:26: note: in definition of macro 'container_of' void *__mptr = (void *)(ptr); \ ^~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ In file included from arch/x86/include/asm/current.h:5:0, from include/linux/sched.h:12, from arch/x86/pci/common.c:8: arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var' #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond)) ^~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:996:20: note: in expansion of macro '__same_type' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:58:52: note: in definition of macro '__trace_if_var' #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond)) ^~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:997:6: note: in expansion of macro '__same_type' !__same_type(*(ptr), void), \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:58:61: note: in definition of macro '__trace_if_var' #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond)) ^~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:996:20: note: in expansion of macro '__same_type' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:58:61: note: in definition of macro '__trace_if_var' #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond)) ^~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:997:6: note: in expansion of macro '__same_type' !__same_type(*(ptr), void), \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:69:3: note: in definition of macro '__trace_if_value' (cond) ? \ ^~~~ include/linux/compiler.h:56:28: note: in expansion of macro '__trace_if_var' #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) ) ^~~~~~~~~~~~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:996:20: note: in expansion of macro '__same_type' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ arch/x86/pci/common.c:670:35: error: 'struct pci_sysdata' has no member named 'vmd_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^ include/linux/compiler.h:69:3: note: in definition of macro '__trace_if_value' (cond) ? \ ^~~~ include/linux/compiler.h:56:28: note: in expansion of macro '__trace_if_var' #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) ) ^~~~~~~~~~~~~~ >> include/linux/compiler.h:330:3: note: in expansion of macro 'if' if (!(condition)) \ ^~ include/linux/compiler.h:338:2: note: in expansion of macro '__compiletime_assert' __compiletime_assert(condition, msg, prefix, suffix) ^~~~~~~~~~~~~~~~~~~~ include/linux/compiler.h:350:2: note: in expansion of macro '_compiletime_assert' _compiletime_assert(condition, msg, __compiletime_assert_, __LINE__) ^~~~~~~~~~~~~~~~~~~ include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert' #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg) ^~~~~~~~~~~~~~~~~~ include/linux/kernel.h:996:2: note: in expansion of macro 'BUILD_BUG_ON_MSG' BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \ ^~~~~~~~~~~~~~~~ include/linux/kernel.h:997:6: note: in expansion of macro '__same_type' !__same_type(*(ptr), void), \ ^~~~~~~~~~~ include/linux/pci.h:486:23: note: in expansion of macro 'container_of' #define to_pci_dev(n) container_of(n, struct pci_dev, dev) ^~~~~~~~~~~~ arch/x86/pci/common.c:670:22: note: in expansion of macro 'to_pci_dev' pdev->dma_parent = to_pci_dev(sd->vmd_dev); ^~~~~~~~~~ vim +/if +330 include/linux/compiler.h c361d3e54364d1 Daniel Santos 2013-02-21 325 c03567a8e8d5cf Joe Stringer 2017-08-31 326 #ifdef __OPTIMIZE__ 9a8ab1c39970a4 Daniel Santos 2013-02-21 327 # define __compiletime_assert(condition, msg, prefix, suffix) \ 9a8ab1c39970a4 Daniel Santos 2013-02-21 328 do { \ 9a8ab1c39970a4 Daniel Santos 2013-02-21 329 extern void prefix ## suffix(void) __compiletime_error(msg); \ 81b45683487a51 Masahiro Yamada 2018-08-26 @330 if (!(condition)) \ 9a8ab1c39970a4 Daniel Santos 2013-02-21 331 prefix ## suffix(); \ 9a8ab1c39970a4 Daniel Santos 2013-02-21 332 } while (0) c03567a8e8d5cf Joe Stringer 2017-08-31 333 #else c03567a8e8d5cf Joe Stringer 2017-08-31 334 # define __compiletime_assert(condition, msg, prefix, suffix) do { } while (0) c03567a8e8d5cf Joe Stringer 2017-08-31 335 #endif 9a8ab1c39970a4 Daniel Santos 2013-02-21 336 :::::: The code at line 330 was first introduced by commit :::::: 81b45683487a51b0f4d3b29d37f20d6d078544e4 compiler.h: give up __compiletime_assert_fallback() :::::: TO: Masahiro Yamada :::::: CC: Kees Cook --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org Intel Corporation