diff options
author | Sami Tolvanen <samitolvanen@google.com> | 2020-12-11 10:46:18 -0800 |
---|---|---|
committer | Kees Cook <keescook@chromium.org> | 2021-01-08 15:59:02 -0800 |
commit | 3b15cdc15956673ba1551d79bceae471436ac6a9 (patch) | |
tree | 5dc22bbb44d06225d4014bf7dadb1e3cfd5ec678 /scripts/Makefile.build | |
parent | e71ba9452f0b5b2e8dc8aa5445198cd9214a6a62 (diff) | |
download | linux-3b15cdc15956673ba1551d79bceae471436ac6a9.tar.gz linux-3b15cdc15956673ba1551d79bceae471436ac6a9.tar.bz2 linux-3b15cdc15956673ba1551d79bceae471436ac6a9.zip |
tracing: move function tracer options to Kconfig
Move function tracer options to Kconfig to make it easier to add
new methods for generating __mcount_loc, and to make the options
available also when building kernel modules.
Note that FTRACE_MCOUNT_USE_* options are updated on rebuild and
therefore, work even if the .config was generated in a different
environment.
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
Acked-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20201211184633.3213045-2-samitolvanen@google.com
Diffstat (limited to 'scripts/Makefile.build')
-rw-r--r-- | scripts/Makefile.build | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 4c058f12dd73..22654a463ad8 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build @@ -178,8 +178,7 @@ cmd_modversions_c = \ fi endif -ifdef CONFIG_FTRACE_MCOUNT_RECORD -ifndef CC_USING_RECORD_MCOUNT +ifdef CONFIG_FTRACE_MCOUNT_USE_RECORDMCOUNT # compiler will not generate __mcount_loc use recordmcount or recordmcount.pl ifdef BUILD_C_RECORDMCOUNT ifeq ("$(origin RECORDMCOUNT_WARN)", "command line") @@ -206,8 +205,7 @@ recordmcount_source := $(srctree)/scripts/recordmcount.pl endif # BUILD_C_RECORDMCOUNT cmd_record_mcount = $(if $(findstring $(strip $(CC_FLAGS_FTRACE)),$(_c_flags)), \ $(sub_cmd_record_mcount)) -endif # CC_USING_RECORD_MCOUNT -endif # CONFIG_FTRACE_MCOUNT_RECORD +endif # CONFIG_FTRACE_MCOUNT_USE_RECORDMCOUNT ifdef CONFIG_STACK_VALIDATION ifneq ($(SKIP_STACK_VALIDATION),1) |