From: kernel test robot <lkp@intel.com>
To: thinker.li@gmail.com
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [RFC bpf-next v3 07/11] bpf, net: switch to storing struct_ops in btf
Date: Mon, 25 Sep 2023 16:30:38 +0800 [thread overview]
Message-ID: <202309251600.fzViZTWK-lkp@intel.com> (raw)
In-Reply-To: <20230920155923.151136-8-thinker.li@gmail.com>
Hi,
[This is a private test report for your RFC patch.]
kernel test robot noticed the following build warnings:
[auto build test WARNING on bpf-next/master]
url: https://github.com/intel-lab-lkp/linux/commits/thinker-li-gmail-com/bpf-refactory-struct_ops-type-initialization-to-a-function/20230921-000546
base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
patch link: https://lore.kernel.org/r/20230920155923.151136-8-thinker.li%40gmail.com
patch subject: [RFC bpf-next v3 07/11] bpf, net: switch to storing struct_ops in btf
config: x86_64-randconfig-016-20230925 (https://download.01.org/0day-ci/archive/20230925/202309251600.fzViZTWK-lkp@intel.com/config)
compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20230925/202309251600.fzViZTWK-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/202309251600.fzViZTWK-lkp@intel.com/
All warnings (new ones prefixed by >>):
kernel/bpf/bpf_struct_ops.c: In function 'bpf_struct_ops_init':
kernel/bpf/bpf_struct_ops.c:252:8: error: implicit declaration of function 'register_bpf_struct_ops'; did you mean 'register_net_sysctl_sz'? [-Werror=implicit-function-declaration]
ret = register_bpf_struct_ops(&bpf_testmod_struct_ops);
^~~~~~~~~~~~~~~~~~~~~~~
register_net_sysctl_sz
kernel/bpf/bpf_struct_ops.c: At top level:
>> kernel/bpf/bpf_struct_ops.c:258:5: warning: no previous declaration for 'register_bpf_struct_ops' [-Wmissing-declarations]
int register_bpf_struct_ops(struct bpf_struct_ops_mod *mod)
^~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/register_bpf_struct_ops +258 kernel/bpf/bpf_struct_ops.c
257
> 258 int register_bpf_struct_ops(struct bpf_struct_ops_mod *mod)
259 {
260 struct bpf_struct_ops *st_ops = mod->st_ops;
261 struct bpf_verifier_log *log;
262 struct btf *btf;
263 int err;
264
265 if (mod->st_ops == NULL ||
266 mod->owner == NULL)
267 return -EINVAL;
268
269 log = kzalloc(sizeof(*log), GFP_KERNEL | __GFP_NOWARN);
270 if (!log) {
271 err = -ENOMEM;
272 goto errout;
273 }
274
275 log->level = BPF_LOG_KERNEL;
276
277 btf = btf_get_module_btf(mod->owner);
278 if (!btf) {
279 err = -EINVAL;
280 goto errout;
281 }
282
283 bpf_struct_ops_init_one(st_ops, btf, log);
284
285 btf_put(btf);
286
287 st_ops->owner = mod->owner;
288 err = btf_add_struct_ops(st_ops, st_ops->owner);
289
290 errout:
291 kfree(log);
292
293 return err;
294 }
295 EXPORT_SYMBOL_GPL(register_bpf_struct_ops);
296
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2023-09-25 8:31 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-20 15:59 [RFC bpf-next v3 00/11] Registrating struct_ops types from modules thinker.li
2023-09-20 15:59 ` [RFC bpf-next v3 01/11] bpf: refactory struct_ops type initialization to a function thinker.li
2023-09-20 15:59 ` [RFC bpf-next v3 02/11] bpf: add struct_ops_tab to btf thinker.li
2023-09-25 21:10 ` Martin KaFai Lau
2023-09-25 21:45 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 03/11] bpf: add register and unregister functions for struct_ops thinker.li
2023-09-25 23:07 ` Martin KaFai Lau
2023-09-25 23:13 ` Kui-Feng Lee
2023-09-25 23:31 ` Martin KaFai Lau
2023-09-26 0:19 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 04/11] bpf: attach a module BTF to a bpf_struct_ops thinker.li
2023-09-25 22:57 ` Martin KaFai Lau
2023-09-25 23:25 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 05/11] bpf: hold module for bpf_struct_ops_map thinker.li
2023-09-25 23:23 ` Martin KaFai Lau
2023-09-25 23:42 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 06/11] bpf: validate value_type thinker.li
2023-09-26 1:03 ` Martin KaFai Lau
2023-09-27 20:27 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 07/11] bpf, net: switch to storing struct_ops in btf thinker.li
2023-09-20 23:45 ` kernel test robot
2023-09-24 3:23 ` kernel test robot
2023-09-25 8:30 ` kernel test robot [this message]
2023-09-26 0:02 ` Martin KaFai Lau
2023-09-26 0:18 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 08/11] bpf: pass attached BTF to find correct type info of struct_ops progs thinker.li
2023-09-25 22:58 ` Andrii Nakryiko
2023-09-25 23:50 ` Kui-Feng Lee
2023-09-26 0:24 ` Martin KaFai Lau
2023-09-26 0:58 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 09/11] libbpf: Find correct module BTFs for struct_ops maps and progs thinker.li
2023-09-25 23:09 ` Andrii Nakryiko
2023-09-26 0:12 ` Kui-Feng Lee
2023-09-20 15:59 ` [RFC bpf-next v3 10/11] bpf: export btf_ctx_access to modules thinker.li
2023-09-20 15:59 ` [RFC bpf-next v3 11/11] selftests/bpf: test case for register_bpf_struct_ops() thinker.li
2023-09-26 1:19 ` Martin KaFai Lau
2023-09-26 1:33 ` [RFC bpf-next v3 00/11] Registrating struct_ops types from modules Martin KaFai Lau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202309251600.fzViZTWK-lkp@intel.com \
--to=lkp@intel.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=thinker.li@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.