tracing: Disable kcov on trace_preemptirq.c
authorCongyu Liu <liu3101@purdue.edu>
Mon, 23 May 2022 06:30:33 +0000 (06:30 +0000)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Fri, 27 May 2022 01:13:00 +0000 (21:13 -0400)
Functions in trace_preemptirq.c could be invoked from early interrupt
code that bypasses kcov trace function's in_task() check. Disable kcov
on this file to reduce random code coverage.

Link: https://lkml.kernel.org/r/20220523063033.1778974-1-liu3101@purdue.edu
Acked-by: Dmitry Vyukov <dvyukov@google.com>
Signed-off-by: Congyu Liu <liu3101@purdue.edu>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
kernel/trace/Makefile

index d77cd80..0d26177 100644 (file)
@@ -31,6 +31,10 @@ ifdef CONFIG_GCOV_PROFILE_FTRACE
 GCOV_PROFILE := y
 endif
 
+# Functions in this file could be invoked from early interrupt
+# code and produce random code coverage.
+KCOV_INSTRUMENT_trace_preemptirq.o := n
+
 CFLAGS_bpf_trace.o := -I$(src)
 
 CFLAGS_trace_benchmark.o := -I$(src)