aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/trace/trace.h')
-rw-r--r--kernel/trace/trace.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h
index 40211cef2796..d1cf5159bec0 100644
--- a/kernel/trace/trace.h
+++ b/kernel/trace/trace.h
@@ -732,6 +732,8 @@ extern void __trace_graph_return(struct trace_array *tr,
732#define FTRACE_GRAPH_MAX_FUNCS 32 732#define FTRACE_GRAPH_MAX_FUNCS 32
733extern int ftrace_graph_count; 733extern int ftrace_graph_count;
734extern unsigned long ftrace_graph_funcs[FTRACE_GRAPH_MAX_FUNCS]; 734extern unsigned long ftrace_graph_funcs[FTRACE_GRAPH_MAX_FUNCS];
735extern int ftrace_graph_notrace_count;
736extern unsigned long ftrace_graph_notrace_funcs[FTRACE_GRAPH_MAX_FUNCS];
735 737
736static inline int ftrace_graph_addr(unsigned long addr) 738static inline int ftrace_graph_addr(unsigned long addr)
737{ 739{
@@ -757,11 +759,31 @@ static inline int ftrace_graph_addr(unsigned long addr)
757 759
758 return 0; 760 return 0;
759} 761}
762
763static inline int ftrace_graph_notrace_addr(unsigned long addr)
764{
765 int i;
766
767 if (!ftrace_graph_notrace_count)
768 return 0;
769
770 for (i = 0; i < ftrace_graph_notrace_count; i++) {
771 if (addr == ftrace_graph_notrace_funcs[i])
772 return 1;
773 }
774
775 return 0;
776}
760#else 777#else
761static inline int ftrace_graph_addr(unsigned long addr) 778static inline int ftrace_graph_addr(unsigned long addr)
762{ 779{
763 return 1; 780 return 1;
764} 781}
782
783static inline int ftrace_graph_notrace_addr(unsigned long addr)
784{
785 return 0;
786}
765#endif /* CONFIG_DYNAMIC_FTRACE */ 787#endif /* CONFIG_DYNAMIC_FTRACE */
766#else /* CONFIG_FUNCTION_GRAPH_TRACER */ 788#else /* CONFIG_FUNCTION_GRAPH_TRACER */
767static inline enum print_line_t 789static inline enum print_line_t