From: kernel test robot <lkp@intel.com>
To: Jiri Olsa <jolsa@kernel.org>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [jolsa-perf:bpf/single_direct_ops_ci 11/11] kernel/bpf/trampoline.c:331:9: error: call to undeclared function 'direct_ops_del'; ISO C99 and later do not support implicit function declarations
Date: Fri, 21 Nov 2025 16:18:42 +0800 [thread overview]
Message-ID: <202511211659.KNKOM3Kt-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/single_direct_ops_ci
head: 60a0e23f31d3e7eb62bf1ff14f9efef8de96ac0d
commit: 60a0e23f31d3e7eb62bf1ff14f9efef8de96ac0d [11/11] bpf, x86: Use single ftrace_ops for direct calls
config: s390-randconfig-002-20251121 (https://download.01.org/0day-ci/archive/20251121/202511211659.KNKOM3Kt-lkp@intel.com/config)
compiler: clang version 19.1.7 (https://github.com/llvm/llvm-project cd708029e0b2869e80abe31ddb175f7c35361f90)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251121/202511211659.KNKOM3Kt-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/202511211659.KNKOM3Kt-lkp@intel.com/
All errors (new ones prefixed by >>):
>> kernel/bpf/trampoline.c:331:9: error: call to undeclared function 'direct_ops_del'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
331 | ret = direct_ops_del(tr->fops, tr->ip, old_addr);
| ^
kernel/bpf/trampoline.c:331:9: note: did you mean 'direct_ops_free'?
kernel/bpf/trampoline.c:281:13: note: 'direct_ops_free' declared here
281 | static void direct_ops_free(struct bpf_trampoline *tr) { }
| ^
>> kernel/bpf/trampoline.c:345:9: error: call to undeclared function 'direct_ops_mod'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
345 | ret = direct_ops_mod(tr->fops, tr->ip, new_addr, lock_direct_mutex);
| ^
kernel/bpf/trampoline.c:345:9: note: did you mean 'direct_ops_free'?
kernel/bpf/trampoline.c:281:13: note: 'direct_ops_free' declared here
281 | static void direct_ops_free(struct bpf_trampoline *tr) { }
| ^
>> kernel/bpf/trampoline.c:367:9: error: call to undeclared function 'direct_ops_add'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
367 | ret = direct_ops_add(tr->fops, tr->ip, new_addr);
| ^
kernel/bpf/trampoline.c:367:9: note: did you mean 'direct_ops_free'?
kernel/bpf/trampoline.c:281:13: note: 'direct_ops_free' declared here
281 | static void direct_ops_free(struct bpf_trampoline *tr) { }
| ^
3 errors generated.
vim +/direct_ops_del +331 kernel/bpf/trampoline.c
324
325 static int unregister_fentry(struct bpf_trampoline *tr, void *old_addr)
326 {
327 void *ip = tr->func.addr;
328 int ret;
329
330 if (tr->func.ftrace_managed)
> 331 ret = direct_ops_del(tr->fops, tr->ip, old_addr);
332 else
333 ret = bpf_arch_text_poke(ip, BPF_MOD_CALL, old_addr, NULL);
334
335 return ret;
336 }
337
338 static int modify_fentry(struct bpf_trampoline *tr, void *old_addr, void *new_addr,
339 bool lock_direct_mutex)
340 {
341 void *ip = tr->func.addr;
342 int ret;
343
344 if (tr->func.ftrace_managed) {
> 345 ret = direct_ops_mod(tr->fops, tr->ip, new_addr, lock_direct_mutex);
346 } else {
347 ret = bpf_arch_text_poke(ip, BPF_MOD_CALL, old_addr, new_addr);
348 }
349 return ret;
350 }
351
352 /* first time registering */
353 static int register_fentry(struct bpf_trampoline *tr, void *new_addr)
354 {
355 void *ip = tr->func.addr;
356 unsigned long faddr;
357 int ret;
358
359 faddr = ftrace_location((unsigned long)ip);
360 if (faddr) {
361 if (!tr->fops)
362 return -ENOTSUPP;
363 tr->func.ftrace_managed = true;
364 }
365
366 if (tr->func.ftrace_managed) {
> 367 ret = direct_ops_add(tr->fops, tr->ip, new_addr);
368 } else {
369 ret = bpf_arch_text_poke(ip, BPF_MOD_CALL, NULL, new_addr);
370 }
371
372 return ret;
373 }
374
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2025-11-21 8:19 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202511211659.KNKOM3Kt-lkp@intel.com \
--to=lkp@intel.com \
--cc=jolsa@kernel.org \
--cc=llvm@lists.linux.dev \
--cc=oe-kbuild-all@lists.linux.dev \
/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 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).