tracing: add support for objtool mcount

This change adds build support for using objtool to generate
__mcount_loc sections.

Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
This commit is contained in:
Sami Tolvanen
2020-09-25 16:43:53 -07:00
committed by Kees Cook
parent 0e731dbc18
commit 22c8542d7b
3 changed files with 23 additions and 0 deletions

View File

@@ -238,6 +238,9 @@ endif
ifdef CONFIG_X86_SMAP
objtool_args += --uaccess
endif
ifdef CONFIG_FTRACE_MCOUNT_USE_OBJTOOL
objtool_args += --mcount
endif
# 'OBJECT_FILES_NON_STANDARD := y': skip objtool checking for a directory
# 'OBJECT_FILES_NON_STANDARD_foo.o := 'y': skip objtool checking for a file