Content-Type: multipart/mixed; boundary="===============5857811095983231159==" MIME-Version: 1.0 From: kernel test robot To: kbuild-all@lists.01.org Subject: Re: [PATCH 1/2] cgroup: add cpu.stat_percpu Date: Sat, 08 Jan 2022 19:03:43 +0800 Message-ID: <202201081834.qK6yea4m-lkp@intel.com> In-Reply-To: <20220107234138.1765668-1-joshdon@google.com> List-Id: --===============5857811095983231159== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Josh, Thank you for the patch! Yet something to improve: [auto build test ERROR on tj-cgroup/for-next] [also build test ERROR on tip/sched/core tip/master v5.16-rc8 next-20220107] [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] url: https://github.com/0day-ci/linux/commits/Josh-Don/cgroup-add-cpu-st= at_percpu/20220108-074316 base: https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git for-n= ext config: x86_64-randconfig-a014-20220107 (https://download.01.org/0day-ci/ar= chive/20220108/202201081834.qK6yea4m-lkp(a)intel.com/config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project f3a344= d2125fa37e59bae1b0874442c650a19607) reproduce (this is a W=3D1 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/d70517c43ca623321dcca220c= e4c9b93059dc763 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Josh-Don/cgroup-add-cpu-stat_percp= u/20220108-074316 git checkout d70517c43ca623321dcca220ce4c9b93059dc763 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=3D$HOME/0day COMPILER=3Dclang make.cross W=3D= 1 O=3Dbuild_dir ARCH=3Dx86_64 SHELL=3D/bin/bash If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>): >> kernel/cgroup/rstat.c:519:9: error: '__section__' attribute only applies= to functions, global variables, Objective-C methods, and Objective-C prope= rties static DEFINE_PER_CPU(struct cgroup_base_stat, cached_percpu_sta= ts); ^ include/linux/percpu-defs.h:115:2: note: expanded from macro 'DEFINE_PER= _CPU' DEFINE_PER_CPU_SECTION(type, name, "") ^ include/linux/percpu-defs.h:93:2: note: expanded from macro 'DEFINE_PER_= CPU_SECTION' __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ ^ include/linux/percpu-defs.h:54:2: note: expanded from macro '__PCPU_DUMM= Y_ATTRS' __section(".discard") __attribute__((unused)) ^ include/linux/compiler_attributes.h:276:56: note: expanded from macro '_= _section' #define __section(section) __attribute__((__section__(secti= on))) ^ >> kernel/cgroup/rstat.c:519:9: error: non-extern declaration of '__pcpu_un= ique_cached_percpu_stats' follows extern declaration include/linux/percpu-defs.h:115:2: note: expanded from macro 'DEFINE_PER= _CPU' DEFINE_PER_CPU_SECTION(type, name, "") ^ include/linux/percpu-defs.h:93:26: note: expanded from macro 'DEFINE_PER= _CPU_SECTION' __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ ^ :66:1: note: expanded from here __pcpu_unique_cached_percpu_stats ^ kernel/cgroup/rstat.c:519:9: note: previous declaration is here include/linux/percpu-defs.h:115:2: note: expanded from macro 'DEFINE_PER= _CPU' DEFINE_PER_CPU_SECTION(type, name, "") ^ include/linux/percpu-defs.h:92:33: note: expanded from macro 'DEFINE_PER= _CPU_SECTION' extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ ^ :65:1: note: expanded from here __pcpu_unique_cached_percpu_stats ^ >> kernel/cgroup/rstat.c:519:9: error: 'section' attribute only applies to = functions, global variables, Objective-C methods, and Objective-C properties static DEFINE_PER_CPU(struct cgroup_base_stat, cached_percpu_sta= ts); ^ include/linux/percpu-defs.h:115:2: note: expanded from macro 'DEFINE_PER= _CPU' DEFINE_PER_CPU_SECTION(type, name, "") ^ include/linux/percpu-defs.h:95:2: note: expanded from macro 'DEFINE_PER_= CPU_SECTION' __PCPU_ATTRS(sec) __weak __typeof__(type) name ^ include/linux/percpu-defs.h:50:26: note: expanded from macro '__PCPU_ATT= RS' __percpu __attribute__((section(PER_CPU_BASE_SECTION sec))) \ ^ >> kernel/cgroup/rstat.c:519:49: error: non-extern declaration of 'cached_p= ercpu_stats' follows extern declaration static DEFINE_PER_CPU(struct cgroup_base_stat, cached_percpu_sta= ts); ^ kernel/cgroup/rstat.c:519:49: note: previous declaration is here >> kernel/cgroup/rstat.c:519:9: error: weak declaration cannot have interna= l linkage static DEFINE_PER_CPU(struct cgroup_base_stat, cached_percpu_sta= ts); ^ include/linux/percpu-defs.h:115:2: note: expanded from macro 'DEFINE_PER= _CPU' DEFINE_PER_CPU_SECTION(type, name, "") ^ include/linux/percpu-defs.h:95:20: note: expanded from macro 'DEFINE_PER= _CPU_SECTION' __PCPU_ATTRS(sec) __weak __typeof__(type) name ^ include/linux/compiler_attributes.h:315:56: note: expanded from macro '_= _weak' #define __weak __attribute__((__weak__)) ^ 5 errors generated. vim +/__section__ +519 kernel/cgroup/rstat.c 515 = 516 void cgroup_base_stat_percpu_cputime_show(struct seq_file *seq) 517 { 518 static DEFINE_MUTEX(mutex); > 519 static DEFINE_PER_CPU(struct cgroup_base_stat, cached_percpu_stats); --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org --===============5857811095983231159==--