18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0 28c2ecf20Sopenharmony_ciifndef NO_DWARF 38c2ecf20Sopenharmony_ciPERF_HAVE_DWARF_REGS := 1 48c2ecf20Sopenharmony_ciendif 58c2ecf20Sopenharmony_ci 68c2ecf20Sopenharmony_ciHAVE_KVM_STAT_SUPPORT := 1 78c2ecf20Sopenharmony_ciPERF_HAVE_ARCH_REGS_QUERY_REGISTER_OFFSET := 1 88c2ecf20Sopenharmony_ciPERF_HAVE_JITDUMP := 1 98c2ecf20Sopenharmony_ci 108c2ecf20Sopenharmony_ci# 118c2ecf20Sopenharmony_ci# Syscall table generation for perf 128c2ecf20Sopenharmony_ci# 138c2ecf20Sopenharmony_ci 148c2ecf20Sopenharmony_ciout := $(OUTPUT)arch/powerpc/include/generated/asm 158c2ecf20Sopenharmony_ciheader32 := $(out)/syscalls_32.c 168c2ecf20Sopenharmony_ciheader64 := $(out)/syscalls_64.c 178c2ecf20Sopenharmony_cisyskrn := $(srctree)/arch/powerpc/kernel/syscalls/syscall.tbl 188c2ecf20Sopenharmony_cisysprf := $(srctree)/tools/perf/arch/powerpc/entry/syscalls 198c2ecf20Sopenharmony_cisysdef := $(sysprf)/syscall.tbl 208c2ecf20Sopenharmony_cisystbl := $(sysprf)/mksyscalltbl 218c2ecf20Sopenharmony_ci 228c2ecf20Sopenharmony_ci# Create output directory if not already present 238c2ecf20Sopenharmony_ci_dummy := $(shell [ -d '$(out)' ] || mkdir -p '$(out)') 248c2ecf20Sopenharmony_ci 258c2ecf20Sopenharmony_ci$(header64): $(sysdef) $(systbl) 268c2ecf20Sopenharmony_ci @(test -d ../../kernel -a -d ../../tools -a -d ../perf && ( \ 278c2ecf20Sopenharmony_ci (diff -B $(sysdef) $(syskrn) >/dev/null) \ 288c2ecf20Sopenharmony_ci || echo "Warning: Kernel ABI header at '$(sysdef)' differs from latest version at '$(syskrn)'" >&2 )) || true 298c2ecf20Sopenharmony_ci $(Q)$(SHELL) '$(systbl)' '64' $(sysdef) > $@ 308c2ecf20Sopenharmony_ci 318c2ecf20Sopenharmony_ci$(header32): $(sysdef) $(systbl) 328c2ecf20Sopenharmony_ci @(test -d ../../kernel -a -d ../../tools -a -d ../perf && ( \ 338c2ecf20Sopenharmony_ci (diff -B $(sysdef) $(syskrn) >/dev/null) \ 348c2ecf20Sopenharmony_ci || echo "Warning: Kernel ABI header at '$(sysdef)' differs from latest version at '$(syskrn)'" >&2 )) || true 358c2ecf20Sopenharmony_ci $(Q)$(SHELL) '$(systbl)' '32' $(sysdef) > $@ 368c2ecf20Sopenharmony_ci 378c2ecf20Sopenharmony_ciclean:: 388c2ecf20Sopenharmony_ci $(call QUIET_CLEAN, powerpc) $(RM) $(header32) $(header64) 398c2ecf20Sopenharmony_ci 408c2ecf20Sopenharmony_ciarchheaders: $(header32) $(header64) 41