* Re: [RFC PATCH bpf-next 1/4] bpf: Introduce css_task open-coded iterator kfuncs
[not found] <20230827072057.1591929-2-zhouchuyi@bytedance.com>
@ 2023-08-27 9:14 ` kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-08-27 9:14 UTC (permalink / raw)
To: Chuyi Zhou; +Cc: llvm, oe-kbuild-all
Hi Chuyi,
[This is a private test report for your RFC patch.]
kernel test robot noticed the following build errors:
[auto build test ERROR on bpf-next/master]
url: https://github.com/intel-lab-lkp/linux/commits/Chuyi-Zhou/bpf-Introduce-css_task-open-coded-iterator-kfuncs/20230827-152340
base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
patch link: https://lore.kernel.org/r/20230827072057.1591929-2-zhouchuyi%40bytedance.com
patch subject: [RFC PATCH bpf-next 1/4] bpf: Introduce css_task open-coded iterator kfuncs
config: riscv-randconfig-r005-20230827 (https://download.01.org/0day-ci/archive/20230827/202308271613.AkJ57Io7-lkp@intel.com/config)
compiler: clang version 17.0.0 (https://github.com/llvm/llvm-project.git 4a5ac14ee968ff0ad5d2cc1ffa0299048db4c88a)
reproduce: (https://download.01.org/0day-ci/archive/20230827/202308271613.AkJ57Io7-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202308271613.AkJ57Io7-lkp@intel.com/
All error/warnings (new ones prefixed by >>):
>> kernel/bpf/task_iter.c:839:24: error: invalid application of 'sizeof' to an incomplete type 'struct css_task_iter'
839 | kit->css_it = kzalloc(sizeof(struct css_task_iter), GFP_KERNEL);
| ^ ~~~~~~~~~~~~~~~~~~~~~~
kernel/bpf/task_iter.c:827:9: note: forward declaration of 'struct css_task_iter'
827 | struct css_task_iter *css_it;
| ^
>> kernel/bpf/task_iter.c:842:2: error: call to undeclared function 'css_task_iter_start'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
842 | css_task_iter_start(css, flags, kit->css_it);
| ^
kernel/bpf/task_iter.c:842:2: note: did you mean '__sg_page_iter_start'?
include/linux/scatterlist.h:573:6: note: '__sg_page_iter_start' declared here
573 | void __sg_page_iter_start(struct sg_page_iter *piter,
| ^
>> kernel/bpf/task_iter.c:830:17: warning: no previous prototype for function 'bpf_iter_css_task_new' [-Wmissing-prototypes]
830 | __bpf_kfunc int bpf_iter_css_task_new(struct bpf_iter_css_task *it,
| ^
kernel/bpf/task_iter.c:830:13: note: declare 'static' if the function is not intended to be used outside of this translation unit
830 | __bpf_kfunc int bpf_iter_css_task_new(struct bpf_iter_css_task *it,
| ^
| static
>> kernel/bpf/task_iter.c:852:9: error: call to undeclared function 'css_task_iter_next'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
852 | return css_task_iter_next(kit->css_it);
| ^
>> kernel/bpf/task_iter.c:852:9: error: incompatible integer to pointer conversion returning 'int' from a function with result type 'struct task_struct *' [-Wint-conversion]
852 | return css_task_iter_next(kit->css_it);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> kernel/bpf/task_iter.c:846:33: warning: no previous prototype for function 'bpf_iter_css_task_next' [-Wmissing-prototypes]
846 | __bpf_kfunc struct task_struct *bpf_iter_css_task_next(struct bpf_iter_css_task *it)
| ^
kernel/bpf/task_iter.c:846:13: note: declare 'static' if the function is not intended to be used outside of this translation unit
846 | __bpf_kfunc struct task_struct *bpf_iter_css_task_next(struct bpf_iter_css_task *it)
| ^
| static
>> kernel/bpf/task_iter.c:861:2: error: call to undeclared function 'css_task_iter_end'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
861 | css_task_iter_end(kit->css_it);
| ^
>> kernel/bpf/task_iter.c:855:18: warning: no previous prototype for function 'bpf_iter_css_task_destroy' [-Wmissing-prototypes]
855 | __bpf_kfunc void bpf_iter_css_task_destroy(struct bpf_iter_css_task *it)
| ^
kernel/bpf/task_iter.c:855:13: note: declare 'static' if the function is not intended to be used outside of this translation unit
855 | __bpf_kfunc void bpf_iter_css_task_destroy(struct bpf_iter_css_task *it)
| ^
| static
3 warnings and 5 errors generated.
vim +839 kernel/bpf/task_iter.c
829
> 830 __bpf_kfunc int bpf_iter_css_task_new(struct bpf_iter_css_task *it,
831 struct cgroup_subsys_state *css, unsigned int flags)
832 {
833 struct bpf_iter_css_task_kern *kit = (void *)it;
834
835 BUILD_BUG_ON(sizeof(struct bpf_iter_css_task_kern) != sizeof(struct bpf_iter_css_task));
836 BUILD_BUG_ON(__alignof__(struct bpf_iter_css_task_kern) !=
837 __alignof__(struct bpf_iter_css_task));
838
> 839 kit->css_it = kzalloc(sizeof(struct css_task_iter), GFP_KERNEL);
840 if (!kit->css_it)
841 return -ENOMEM;
> 842 css_task_iter_start(css, flags, kit->css_it);
843 return 0;
844 }
845
> 846 __bpf_kfunc struct task_struct *bpf_iter_css_task_next(struct bpf_iter_css_task *it)
847 {
848 struct bpf_iter_css_task_kern *kit = (void *)it;
849
850 if (!kit->css_it)
851 return NULL;
> 852 return css_task_iter_next(kit->css_it);
853 }
854
> 855 __bpf_kfunc void bpf_iter_css_task_destroy(struct bpf_iter_css_task *it)
856 {
857 struct bpf_iter_css_task_kern *kit = (void *)it;
858
859 if (!kit->css_it)
860 return;
> 861 css_task_iter_end(kit->css_it);
862 kfree(kit->css_it);
863 }
864
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-08-27 9:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20230827072057.1591929-2-zhouchuyi@bytedance.com>
2023-08-27 9:14 ` [RFC PATCH bpf-next 1/4] bpf: Introduce css_task open-coded iterator kfuncs kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).