tree:
https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
ftrace/fgraph-multi
head: 978dc256bd4d08df876d58b4fa01ba4cb3926242
commit: af135865534e79074152c9939d2083fce5931fe1 [38/40] function_graph: Move graph
notrace bit to shadow stack global var
config: i386-randconfig-r035-20210416 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
#
https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git/c...
git remote add trace
https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
git fetch --no-tags trace ftrace/fgraph-multi
git checkout af135865534e79074152c9939d2083fce5931fe1
# save the attached .config to linux build tree
make W=1 W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from kernel/trace/trace_output.h:6,
from kernel/trace/ftrace.c:45:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/ftrace.c:29:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/ftrace.c:300:5: warning: no previous prototype for
'__register_ftrace_function' [-Wmissing-prototypes]
300 | int __register_ftrace_function(struct ftrace_ops *ops)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/ftrace.c:343:5: warning: no previous prototype for
'__unregister_ftrace_function' [-Wmissing-prototypes]
343 | int __unregister_ftrace_function(struct ftrace_ops *ops)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/ftrace.c:3872:15: warning: no previous prototype for
'arch_ftrace_match_adjust' [-Wmissing-prototypes]
3872 | char * __weak arch_ftrace_match_adjust(char *str, const char *search)
| ^~~~~~~~~~~~~~~~~~~~~~~~
--
In file included from kernel/trace/trace.c:52:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/trace.c:31:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace.c: In function 'trace_check_vprintf':
kernel/trace/trace.c:3718:3: warning: function 'trace_check_vprintf' might be a
candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
3718 | trace_seq_vprintf(&iter->seq, iter->fmt, ap);
| ^~~~~~~~~~~~~~~~~
kernel/trace/trace.c:3757:3: warning: function 'trace_check_vprintf' might be a
candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
3757 | trace_seq_vprintf(&iter->seq, p, ap);
| ^~~~~~~~~~~~~~~~~
--
In file included from kernel/trace/trace_output.h:6,
from kernel/trace/trace_output.c:14:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/trace_output.c:10:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace_output.c: In function 'trace_output_raw':
kernel/trace/trace_output.c:331:2: warning: function 'trace_output_raw' might
be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
331 | trace_seq_vprintf(s, trace_event_format(iter, fmt), ap);
| ^~~~~~~~~~~~~~~~~
--
In file included from kernel/trace/trace_stat.c:18:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/trace.h:13,
from kernel/trace/trace_stat.c:18:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
--
In file included from kernel/trace/trace_functions.c:20:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/trace_functions.c:16:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace_functions.c: In function 'ftrace_create_function_files':
kernel/trace/trace_functions.c:78:2: error: 'ret' undeclared (first use in this
function); did you mean 'net'?
78 | ret = allocate_fgraph_ops(tr, tr->ops);
| ^~~
| net
kernel/trace/trace_functions.c:78:2: note: each undeclared identifier is reported only
once for each function it appears in
--
In file included from kernel/trace/trace_preemptirq.c:13:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from kernel/trace/trace_preemptirq.c:11:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace_preemptirq.c:88:16: warning: no previous prototype for
'trace_hardirqs_on_caller' [-Wmissing-prototypes]
88 | __visible void trace_hardirqs_on_caller(unsigned long caller_addr)
| ^~~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace_preemptirq.c:103:16: warning: no previous prototype for
'trace_hardirqs_off_caller' [-Wmissing-prototypes]
103 | __visible void trace_hardirqs_off_caller(unsigned long caller_addr)
| ^~~~~~~~~~~~~~~~~~~~~~~~~
--
In file included from kernel/trace/trace_dynevent.h:14,
from kernel/trace/trace_synth.h:5,
from kernel/trace/trace_events_hist.c:22:
> kernel/trace/trace.h:856:2: error: redeclaration of enumerator
'TRACE_GRAPH_NOTRACE_BIT'
856 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from include/linux/ftrace.h:10,
from include/linux/perf_event.h:49,
from include/linux/trace_events.h:10,
from kernel/trace/trace_events_hist.c:18:
include/linux/trace_recursion.h:65:2: note: previous definition of
'TRACE_GRAPH_NOTRACE_BIT' was here
65 | TRACE_GRAPH_NOTRACE_BIT,
| ^~~~~~~~~~~~~~~~~~~~~~~
kernel/trace/trace_events_hist.c: In function 'unregister_field_var_hists':
kernel/trace/trace_events_hist.c:5228:6: warning: variable 'ret' set but not
used [-Wunused-but-set-variable]
5228 | int ret;
| ^~~
vim +/TRACE_GRAPH_NOTRACE_BIT +856 kernel/trace/trace.h
828
829 enum {
830 TRACE_GRAPH_FL = 1,
831
832 /*
833 * In the very unlikely case that an interrupt came in
834 * at a start of graph tracing, and we want to trace
835 * the function in that interrupt, the depth can be greater
836 * than zero, because of the preempted start of a previous
837 * trace. In an even more unlikely case, depth could be 2
838 * if a softirq interrupted the start of graph tracing,
839 * followed by an interrupt preempting a start of graph
840 * tracing in the softirq, and depth can even be 3
841 * if an NMI came in at the start of an interrupt function
842 * that preempted a softirq start of a function that
843 * preempted normal context!!!! Luckily, it can't be
844 * greater than 3, so the next two bits are a mask
845 * of what the depth is when we set TRACE_GRAPH_FL
846 */
847
848 TRACE_GRAPH_DEPTH_START_BIT,
849 TRACE_GRAPH_DEPTH_END_BIT,
850
851 /*
852 * To implement set_graph_notrace, if this bit is set, we ignore
853 * function graph tracing of called functions, until the return
854 * function is called to clear it.
855 */
856 TRACE_GRAPH_NOTRACE_BIT,
857 };
858
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org