[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202204282157.sMS0vx7Y-lkp@intel.com>
Date: Thu, 28 Apr 2022 21:52:08 +0800
From: kernel test robot <lkp@...el.com>
To: Jiri Olsa <jolsa@...nel.org>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [jolsa-perf:bpf/fixes 1/5] include/linux/kallsyms.h:166:19: error:
static declaration of 'kallsyms_on_each_symbol' follows non-static
declaration
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/fixes
head: 35597ce11b848ee8a696d54223d1f7b64cb49cb2
commit: 280f76918c82441cbe72620287fa24cbb7f74353 [1/5] kallsyms: Fully export kallsyms_on_each_symbol function
config: nios2-randconfig-r023-20220428 (https://download.01.org/0day-ci/archive/20220428/202204282157.sMS0vx7Y-lkp@intel.com/config)
compiler: nios2-linux-gcc (GCC) 11.3.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://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git/commit/?id=280f76918c82441cbe72620287fa24cbb7f74353
git remote add jolsa-perf https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
git fetch --no-tags jolsa-perf bpf/fixes
git checkout 280f76918c82441cbe72620287fa24cbb7f74353
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=nios2 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from drivers/tty/sysrq.c:35:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from drivers/tty/sysrq.c:35:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/tty/sysrq.c:412:34: warning: 'sysrq_thaw_op' defined but not used [-Wunused-const-variable=]
412 | static const struct sysrq_key_op sysrq_thaw_op = {
| ^~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from drivers/char/random.c:52:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from drivers/char/random.c:52:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from init/main.c:21:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from init/main.c:21:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
init/main.c:769:20: warning: no previous prototype for 'arch_post_acpi_subsys_init' [-Wmissing-prototypes]
769 | void __init __weak arch_post_acpi_subsys_init(void) { }
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
init/main.c:781:20: warning: no previous prototype for 'mem_encrypt_init' [-Wmissing-prototypes]
781 | void __init __weak mem_encrypt_init(void) { }
| ^~~~~~~~~~~~~~~~
init/main.c:783:20: warning: no previous prototype for 'poking_init' [-Wmissing-prototypes]
783 | void __init __weak poking_init(void) { }
| ^~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from arch/nios2/kernel/sys_nios2.c:15:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from arch/nios2/kernel/sys_nios2.c:15:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
arch/nios2/kernel/sys_nios2.c:21:16: warning: no previous prototype for 'sys_cacheflush' [-Wmissing-prototypes]
21 | asmlinkage int sys_cacheflush(unsigned long addr, unsigned long len,
| ^~~~~~~~~~~~~~
arch/nios2/kernel/sys_nios2.c:57:16: warning: no previous prototype for 'sys_getpagesize' [-Wmissing-prototypes]
57 | asmlinkage int sys_getpagesize(void)
| ^~~~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/kprobes.h:28,
from include/linux/kgdb.h:19,
from arch/nios2/kernel/kgdb.c:12:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/kprobes.h:28,
from include/linux/kgdb.h:19,
from arch/nios2/kernel/kgdb.c:12:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
arch/nios2/kernel/kgdb.c:130:17: warning: no previous prototype for 'kgdb_breakpoint_c' [-Wmissing-prototypes]
130 | asmlinkage void kgdb_breakpoint_c(struct pt_regs *regs)
| ^~~~~~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from arch/nios2/mm/fault.c:27:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from arch/nios2/mm/fault.c:27:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
arch/nios2/mm/fault.c:43:17: warning: no previous prototype for 'do_page_fault' [-Wmissing-prototypes]
43 | asmlinkage void do_page_fault(struct pt_regs *regs, unsigned long cause,
| ^~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from kernel/fork.c:55:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from kernel/fork.c:55:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/fork.c:163:13: warning: no previous prototype for 'arch_release_task_struct' [-Wmissing-prototypes]
163 | void __weak arch_release_task_struct(struct task_struct *tsk)
| ^~~~~~~~~~~~~~~~~~~~~~~~
kernel/fork.c:853:20: warning: no previous prototype for 'arch_task_cache_init' [-Wmissing-prototypes]
853 | void __init __weak arch_task_cache_init(void) { }
| ^~~~~~~~~~~~~~~~~~~~
kernel/fork.c:948:12: warning: no previous prototype for 'arch_dup_task_struct' [-Wmissing-prototypes]
948 | int __weak arch_dup_task_struct(struct task_struct *dst,
| ^~~~~~~~~~~~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/kprobes.h:28,
from include/linux/kgdb.h:19,
from kernel/panic.c:15:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/kprobes.h:28,
from include/linux/kgdb.h:19,
from kernel/panic.c:15:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/panic.c: In function '__warn':
kernel/panic.c:591:17: warning: function '__warn' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
591 | vprintk(args->fmt, args->args);
| ^~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from kernel/exit.c:42:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from kernel/exit.c:42:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/exit.c:1814:13: warning: no previous prototype for 'abort' [-Wmissing-prototypes]
1814 | __weak void abort(void)
| ^~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from include/linux/syscalls_api.h:1,
from kernel/sched/core.c:13:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/perf_event.h:51,
from include/linux/trace_events.h:10,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:88,
from include/linux/syscalls_api.h:1,
from kernel/sched/core.c:13:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/sched/core.c:5235:20: warning: no previous prototype for 'task_sched_runtime' [-Wmissing-prototypes]
5235 | unsigned long long task_sched_runtime(struct task_struct *p)
| ^~~~~~~~~~~~~~~~~~
kernel/sched/core.c:9420:13: warning: no previous prototype for 'sched_init_smp' [-Wmissing-prototypes]
9420 | void __init sched_init_smp(void)
| ^~~~~~~~~~~~~~
kernel/sched/core.c:9448:13: warning: no previous prototype for 'sched_init' [-Wmissing-prototypes]
9448 | void __init sched_init(void)
| ^~~~~~~~~~
--
In file included from include/linux/ftrace.h:13,
from include/linux/livepatch.h:13,
from kernel/sched/build_policy.c:23:
>> include/linux/kallsyms.h:166:19: error: static declaration of 'kallsyms_on_each_symbol' follows non-static declaration
166 | static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:13,
from include/linux/livepatch.h:13,
from kernel/sched/build_policy.c:23:
include/linux/kallsyms.h:68:5: note: previous declaration of 'kallsyms_on_each_symbol' with type 'int(int (*)(void *, const char *, struct module *, long unsigned int), void *)'
68 | int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from kernel/sched/build_policy.c:43:
kernel/sched/rt.c:666:6: warning: no previous prototype for 'sched_rt_bandwidth_account' [-Wmissing-prototypes]
666 | bool sched_rt_bandwidth_account(struct rt_rq *rt_rq)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
..
vim +/kallsyms_on_each_symbol +166 include/linux/kallsyms.h
165
> 166 static inline int kallsyms_on_each_symbol(int (*fn)(void *, const char *, struct module *, unsigned long),
167 void *data)
168 {
169 return -EOPNOTSUPP;
170 }
171 #endif /*CONFIG_KALLSYMS*/
172
--
0-DAY CI Kernel Test Service
https://01.org/lkp
Powered by blists - more mailing lists