Re: [PATCH bpf] treewide: add missing includes masked by cgroup -> bpf dependency

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jakub,

I love your patch! Yet something to improve:

[auto build test ERROR on bpf/master]

url:    https://github.com/0day-ci/linux/commits/Jakub-Kicinski/treewide-add-missing-includes-masked-by-cgroup-bpf-dependency/20211120-115325
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git master
config: riscv-randconfig-m031-20211118 (attached as .config)
compiler: riscv32-linux-gcc (GCC) 11.2.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://github.com/0day-ci/linux/commit/e31b3bdd266ef8f63543f27cf7493e98112fd74a
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Jakub-Kicinski/treewide-add-missing-includes-masked-by-cgroup-bpf-dependency/20211120-115325
        git checkout e31b3bdd266ef8f63543f27cf7493e98112fd74a
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=riscv SHELL=/bin/bash drivers/base/ drivers/iio/dac/ drivers/of/

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

All error/warnings (new ones prefixed by >>):

   In file included from include/linux/cpu.h:17,
                    from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/base/component.c:11:
>> include/linux/node.h:85:25: error: field 'dev' has incomplete type
      85 |         struct device   dev;
         |                         ^~~
   In file included from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/base/component.c:11:
>> include/linux/cpu.h:29:23: error: field 'dev' has incomplete type
      29 |         struct device dev;
         |                       ^~~
>> include/linux/cpu.h:44:36: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      44 | extern int cpu_add_dev_attr(struct device_attribute *attr);
         |                                    ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:45:40: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      45 | extern void cpu_remove_dev_attr(struct device_attribute *attr);
         |                                        ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:51:41: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      51 |                                  struct device_attribute *attr, char *buf);
         |                                         ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:53:43: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      53 |                                    struct device_attribute *attr, char *buf);
         |                                           ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:55:43: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      55 |                                    struct device_attribute *attr, char *buf);
         |                                           ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:57:50: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      57 |                                           struct device_attribute *attr, char *buf);
         |                                                  ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:59:37: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      59 |                              struct device_attribute *attr, char *buf);
         |                                     ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:61:36: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      61 |                             struct device_attribute *attr, char *buf);
         |                                    ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:63:48: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      63 |                                         struct device_attribute *attr,
         |                                                ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:66:46: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      66 |                                       struct device_attribute *attr, char *buf);
         |                                              ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:67:58: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      67 | extern ssize_t cpu_show_srbds(struct device *dev, struct device_attribute *attr, char *buf);
         |                                                          ^~~~~~~~~~~~~~~~
--
   In file included from include/linux/node.h:18,
                    from include/linux/cpu.h:17,
                    from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from drivers/base/driver.c:11:
   include/linux/device.h: In function 'dev_has_sync_state':
>> include/linux/device.h:794:39: error: invalid use of undefined type 'struct device_driver'
     794 |         if (dev->driver && dev->driver->sync_state)
         |                                       ^~
--
   In file included from include/linux/cpu.h:17,
                    from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/base/attribute_container.c:14:
>> include/linux/node.h:85:25: error: field 'dev' has incomplete type
      85 |         struct device   dev;
         |                         ^~~
   In file included from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/base/attribute_container.c:14:
>> include/linux/cpu.h:29:23: error: field 'dev' has incomplete type
      29 |         struct device dev;
         |                       ^~~
--
   In file included from arch/riscv/include/asm/module.h:7,
                    from include/linux/module.h:33,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from include/linux/node.h:18,
                    from include/linux/cpu.h:17,
                    from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/elfcore.h:13,
                    from include/linux/crash_core.h:6,
                    from include/linux/kexec.h:18,
                    from include/linux/crash_dump.h:5,
                    from drivers/of/fdt.c:11:
>> include/asm-generic/module.h:37:25: error: unknown type name 'Elf32_Ehdr'
      37 | #define Elf_Ehdr        Elf32_Ehdr
         |                         ^~~~~~~~~~
   include/linux/module.h:835:32: note: in expansion of macro 'Elf_Ehdr'
     835 | void module_bug_finalize(const Elf_Ehdr *, const Elf_Shdr *,
         |                                ^~~~~~~~
>> include/asm-generic/module.h:33:25: error: unknown type name 'Elf32_Shdr'
      33 | #define Elf_Shdr        Elf32_Shdr
         |                         ^~~~~~~~~~
   include/linux/module.h:835:50: note: in expansion of macro 'Elf_Shdr'
     835 | void module_bug_finalize(const Elf_Ehdr *, const Elf_Shdr *,
         |                                                  ^~~~~~~~
--
   In file included from include/linux/cpu.h:17,
                    from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/iio/dac/ad5755.c:8:
>> include/linux/node.h:85:25: error: field 'dev' has incomplete type
      85 |         struct device   dev;
         |                         ^~~
   In file included from include/linux/cacheinfo.h:6,
                    from arch/riscv/include/asm/cacheinfo.h:9,
                    from arch/riscv/include/asm/elf.h:14,
                    from include/linux/elf.h:6,
                    from include/linux/module.h:19,
                    from include/linux/device/driver.h:21,
                    from include/linux/device.h:32,
                    from drivers/iio/dac/ad5755.c:8:
>> include/linux/cpu.h:29:23: error: field 'dev' has incomplete type
      29 |         struct device dev;
         |                       ^~~
>> include/linux/cpu.h:44:36: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      44 | extern int cpu_add_dev_attr(struct device_attribute *attr);
         |                                    ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:45:40: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      45 | extern void cpu_remove_dev_attr(struct device_attribute *attr);
         |                                        ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:51:41: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      51 |                                  struct device_attribute *attr, char *buf);
         |                                         ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:53:43: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      53 |                                    struct device_attribute *attr, char *buf);
         |                                           ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:55:43: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      55 |                                    struct device_attribute *attr, char *buf);
         |                                           ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:57:50: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      57 |                                           struct device_attribute *attr, char *buf);
         |                                                  ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:59:37: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      59 |                              struct device_attribute *attr, char *buf);
         |                                     ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:61:36: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      61 |                             struct device_attribute *attr, char *buf);
         |                                    ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:63:48: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      63 |                                         struct device_attribute *attr,
         |                                                ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:66:46: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      66 |                                       struct device_attribute *attr, char *buf);
         |                                              ^~~~~~~~~~~~~~~~
   include/linux/cpu.h:67:58: warning: 'struct device_attribute' declared inside parameter list will not be visible outside of this definition or declaration
      67 | extern ssize_t cpu_show_srbds(struct device *dev, struct device_attribute *attr, char *buf);
         |                                                          ^~~~~~~~~~~~~~~~
   drivers/iio/dac/ad5755.c:785:34: warning: 'ad5755_of_match' defined but not used [-Wunused-const-variable=]
     785 | static const struct of_device_id ad5755_of_match[] = {
         |                                  ^~~~~~~~~~~~~~~


vim +/dev +29 include/linux/cpu.h

313162d0b83836 Paul Gortmaker    2012-01-30  25  
^1da177e4c3f41 Linus Torvalds    2005-04-16  26  struct cpu {
^1da177e4c3f41 Linus Torvalds    2005-04-16  27  	int node_id;		/* The node which contains the CPU */
72486f1f8f0a2b Siddha, Suresh B  2006-12-07  28  	int hotpluggable;	/* creates sysfs control file if hotpluggable */
8a25a2fd126c62 Kay Sievers       2011-12-21 @29  	struct device dev;
^1da177e4c3f41 Linus Torvalds    2005-04-16  30  };
^1da177e4c3f41 Linus Torvalds    2005-04-16  31  
cff7d378d3fdbb Thomas Gleixner   2016-02-26  32  extern void boot_cpu_init(void);
b5b1404d081589 Linus Torvalds    2018-08-12  33  extern void boot_cpu_hotplug_init(void);
1777e463550726 Ingo Molnar       2017-02-05  34  extern void cpu_init(void);
1777e463550726 Ingo Molnar       2017-02-05  35  extern void trap_init(void);
cff7d378d3fdbb Thomas Gleixner   2016-02-26  36  
76b67ed9dce69a KAMEZAWA Hiroyuki 2006-06-27  37  extern int register_cpu(struct cpu *cpu, int num);
8a25a2fd126c62 Kay Sievers       2011-12-21  38  extern struct device *get_cpu_device(unsigned cpu);
2987557f52b97f Josh Triplett     2011-12-03  39  extern bool cpu_is_hotpluggable(unsigned cpu);
183912d352a242 Sudeep Holla      2013-08-15  40  extern bool arch_match_cpu_phys_id(int cpu, u64 phys_id);
d1cb9d1af0bc11 David Miller      2013-10-03  41  extern bool arch_find_n_match_cpu_physical_id(struct device_node *cpun,
d1cb9d1af0bc11 David Miller      2013-10-03  42  					      int cpu, unsigned int *thread);
0344c6c5387ba3 Christian Krafft  2006-10-24  43  
8a25a2fd126c62 Kay Sievers       2011-12-21 @44  extern int cpu_add_dev_attr(struct device_attribute *attr);
8a25a2fd126c62 Kay Sievers       2011-12-21  45  extern void cpu_remove_dev_attr(struct device_attribute *attr);
0344c6c5387ba3 Christian Krafft  2006-10-24  46  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux