xref: /optee_os/core/arch/arm/kernel/sub.mk (revision 4576dbb38a6f39534ba4a385eb647b61209f440c)
1ifeq ($(CFG_WITH_USER_TA),y)
2srcs-y += user_ta.c
3srcs-$(CFG_REE_FS_TA) += ree_fs_ta.c
4srcs-$(CFG_EARLY_TA) += early_ta.c
5srcs-$(CFG_SECSTOR_TA) += secstor_ta.c
6endif
7srcs-y += pseudo_ta.c
8srcs-y += tee_time.c
9srcs-y += otp_stubs.c
10srcs-y += delay.c
11
12srcs-$(CFG_SECURE_TIME_SOURCE_CNTPCT) += tee_time_arm_cntpct.c
13srcs-$(CFG_SECURE_TIME_SOURCE_REE) += tee_time_ree.c
14srcs-$(CFG_ARM64_core) += timer_a64.c
15
16srcs-$(CFG_ARM32_core) += spin_lock_a32.S
17srcs-$(CFG_ARM64_core) += spin_lock_a64.S
18srcs-$(CFG_TEE_CORE_DEBUG) += spin_lock_debug.c
19srcs-$(CFG_ARM32_core) += tlb_helpers_a32.S
20srcs-$(CFG_ARM64_core) += tlb_helpers_a64.S
21srcs-$(CFG_ARM64_core) += cache_helpers_a64.S
22srcs-$(CFG_ARM32_core) += cache_helpers_a32.S
23srcs-$(CFG_PL310) += tz_ssvce_pl310_a32.S
24srcs-$(CFG_PL310) += tee_l2cc_mutex.c
25
26srcs-$(CFG_ARM32_core) += thread_a32.S
27srcs-$(CFG_ARM64_core) += thread_a64.S
28srcs-y += thread.c
29srcs-y += thread_optee_smc.c
30srcs-$(CFG_ARM32_core) += thread_optee_smc_a32.S
31srcs-$(CFG_ARM64_core) += thread_optee_smc_a64.S
32srcs-y += abort.c
33srcs-$(CFG_WITH_VFP) += vfp.c
34ifeq ($(CFG_WITH_VFP),y)
35srcs-$(CFG_ARM32_core) += vfp_a32.S
36srcs-$(CFG_ARM64_core) += vfp_a64.S
37endif
38srcs-y += trace_ext.c
39srcs-$(CFG_ARM32_core) += misc_a32.S
40srcs-$(CFG_ARM64_core) += misc_a64.S
41srcs-y += mutex.c
42srcs-$(CFG_LOCKDEP) += mutex_lockdep.c
43srcs-y += wait_queue.c
44srcs-$(CFG_PM_STUBS) += pm_stubs.c
45
46srcs-$(CFG_GENERIC_BOOT) += generic_boot.c
47ifeq ($(CFG_GENERIC_BOOT),y)
48srcs-$(CFG_ARM32_core) += generic_entry_a32.S
49srcs-$(CFG_ARM64_core) += generic_entry_a64.S
50endif
51
52ifeq ($(CFG_UNWIND),y)
53srcs-y += unwind_arm32.c
54srcs-$(CFG_ARM64_core) += unwind_arm64.c
55endif
56
57srcs-$(CFG_VIRTUALIZATION) += virtualization.c
58
59srcs-y += link_dummies_paged.c
60srcs-y += link_dummies_init.c
61
62asm-defines-y += asm-defines.c
63
64ifeq ($(CFG_SYSCALL_FTRACE),y)
65# We would not like to profile thread.c file as it provide common APIs
66# that are needed for ftrace framework to trace syscalls. So profiling
67# this file could create an incorrect cyclic behaviour.
68cflags-remove-thread.c-y += -pg
69cflags-remove-spin_lock_debug.c-$(CFG_TEE_CORE_DEBUG) += -pg
70# Tracing abort dump files corrupts the stack trace. So exclude them
71# from profiling.
72cflags-remove-abort.c-y += -pg
73ifeq ($(CFG_UNWIND),y)
74cflags-remove-unwind_arm32.c-y += -pg
75cflags-remove-unwind_arm64.c-$(CFG_ARM64_core) += -pg
76endif
77endif
78