Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 47239c4d authored by Steven Rostedt's avatar Steven Rostedt Committed by Steven Rostedt
Browse files

ftrace: Only compile ftrace selftest if selftests are enabled



No need to compile in the ftrace selftest helper file if selftests are
not being executed.

Signed-off-by: default avatarSteven Rostedt <rostedt@goodmis.org>
parent 4740974a
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -5,10 +5,12 @@ ifdef CONFIG_FUNCTION_TRACER
ORIG_CFLAGS := $(KBUILD_CFLAGS)
ORIG_CFLAGS := $(KBUILD_CFLAGS)
KBUILD_CFLAGS = $(subst -pg,,$(ORIG_CFLAGS))
KBUILD_CFLAGS = $(subst -pg,,$(ORIG_CFLAGS))


ifdef CONFIG_FTRACE_SELFTEST
# selftest needs instrumentation
# selftest needs instrumentation
CFLAGS_trace_selftest_dynamic.o = -pg
CFLAGS_trace_selftest_dynamic.o = -pg
obj-y += trace_selftest_dynamic.o
obj-y += trace_selftest_dynamic.o
endif
endif
endif


# If unlikely tracing is enabled, do not trace these files
# If unlikely tracing is enabled, do not trace these files
ifdef CONFIG_TRACING_BRANCHES
ifdef CONFIG_TRACING_BRANCHES