1# SPDX-License-Identifier: GPL-2.0 2# 3# Makefile for the powerpc trace subsystem 4# 5 6ifdef CONFIG_FUNCTION_TRACER 7# do not trace tracer code 8CFLAGS_REMOVE_ftrace.o = $(CC_FLAGS_FTRACE) 9CFLAGS_REMOVE_ftrace_64_pg.o = $(CC_FLAGS_FTRACE) 10endif 11 12ifdef CONFIG_FUNCTION_TRACER 13obj32-y += ftrace.o ftrace_entry.o 14ifeq ($(CONFIG_MPROFILE_KERNEL)$(CONFIG_ARCH_USING_PATCHABLE_FUNCTION_ENTRY),) 15obj64-y += ftrace_64_pg.o ftrace_64_pg_entry.o 16else 17obj64-y += ftrace.o ftrace_entry.o 18endif 19endif 20 21obj-$(CONFIG_TRACING) += trace_clock.o 22 23obj-$(CONFIG_PPC64) += $(obj64-y) 24obj-$(CONFIG_PPC32) += $(obj32-y) 25 26# Disable GCOV, KCOV & sanitizers in odd or sensitive code 27GCOV_PROFILE_ftrace.o := n 28KCOV_INSTRUMENT_ftrace.o := n 29KCSAN_SANITIZE_ftrace.o := n 30UBSAN_SANITIZE_ftrace.o := n 31GCOV_PROFILE_ftrace_64_pg.o := n 32KCOV_INSTRUMENT_ftrace_64_pg.o := n 33KCSAN_SANITIZE_ftrace_64_pg.o := n 34UBSAN_SANITIZE_ftrace_64_pg.o := n 35