summaryrefslogtreecommitdiffstats
blob: 530c13b640f5a288125089d22cae1165e84e1f61 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
#
# Copyright (c) 2016-2018, Texas Instruments Incorporated
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# *  Redistributions of source code must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
#
# *  Redistributions in binary form must reproduce the above copyright
#    notice, this list of conditions and the following disclaimer in the
#    documentation and/or other materials provided with the distribution.
#
# *  Neither the name of Texas Instruments Incorporated nor the names of
#    its contributors may be used to endorse or promote products derived
#    from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
# EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#

# File: osal_component.mk
#       This file is component include make file of OSAL library.
# List of variables set in this file and their purpose:
# <mod>_RELPATH        - This is the relative path of the module, typically from
#                        top-level directory of the package
# <mod>_PATH           - This is the absolute path of the module. It derives from
#                        absolute path of the top-level directory (set in env.mk)
#                        and relative path set above
# <mod>_INCLUDE        - This is the path that has interface header files of the
#                        module. This can be multiple directories (space separated)
# <mod>_PKG_LIST       - Names of the modules (and sub-modules) that are a part
#                        part of this module, including itself.
# <mod>_BOARD_DEPENDENCY - "yes": means the code for this module depends on
#                             board and the compiled obj/lib has to be kept
#                             under <board> directory
#                             "no" or "" or if this variable is not defined: means
#                             this module has no baord dependent code and hence
#                             the obj/libs are not kept under <board> dir.
# <mod>_CORE_DEPENDENCY     - "yes": means the code for this module depends on
#                             core and the compiled obj/lib has to be kept
#                             under <core> directory
#                             "no" or "" or if this variable is not defined: means
#                             this module has no core dependent code and hence
#                             the obj/libs are not kept under <core> dir.
# <mod>_APP_STAGE_FILES     - List of source files that belongs to the module
#                             <mod>, but that needs to be compiled at application
#                             build stage (in the context of the app). This is
#                             primarily for link time configurations or if the
#                             source file is dependent on options/defines that are
#                             application dependent. This can be left blank or
#                             not defined at all, in which case, it means there
#                             no source files in the module <mod> that are required
#                             to be compiled in the application build stage.
#
ifeq ($(osal_component_make_include), )

libosal_BOARDLIST       = evmAM572x evmAM335x evmAM437x iceK2G idkAM574x idkAM572x idkAM571x idkAM437x am65xx_evm am65xx_idk evmOMAPL137 lcdkOMAPL138 evmK2E evmK2H evmK2K evmK2L j721e_sim j721e_evm
libosal_SOCLIST         = tda2xx tda2px tda2ex tda3xx dra78x dra72x dra75x am574x am572x am571x k2h k2k k2l k2e k2g c6678 c6657 am437x am335x omapl137 omapl138 am65xx j721e
libosal_tda2xx_CORELIST = a15_0 ipu1_0
libosal_tda2px_CORELIST = a15_0 ipu1_0
libosal_tda2ex_CORELIST = a15_0 ipu1_0
libosal_tda3xx_CORELIST = ipu1_0
libosal_dra72x_CORELIST = c66x a15_0 ipu1_0
libosal_dra75x_CORELIST = c66x a15_0 ipu1_0
libosal_dra78x_CORELIST = c66x ipu1_0
libosal_am574x_CORELIST = c66x a15_0 ipu1_0
libosal_am572x_CORELIST = c66x a15_0 ipu1_0
libosal_am571x_CORELIST = c66x a15_0 ipu1_0
libosal_k2h_CORELIST    = c66x a15_0
libosal_k2k_CORELIST    = c66x a15_0
libosal_k2l_CORELIST    = c66x a15_0
libosal_k2e_CORELIST    = c66x a15_0
libosal_k2g_CORELIST    = c66x a15_0
libosal_omapl137_CORELIST    = c674x arm9_0
libosal_omapl138_CORELIST    = c674x arm9_0
libosal_c6678_CORELIST  = c66x
libosal_c6657_CORELIST  = c66x
libosal_am437x_CORELIST = a9host
libosal_am335x_CORELIST = a8host
libosal_am65xx_CORELIST = mpu1_0 mcu1_0
libosal_j721e_CORELIST = $(DEFAULT_j721e_CORELIST)

############################
# osal package
# List of components included under osal lib
# The components included here are built and will be part of osal lib
############################
osal_LIB_LIST = osal_nonos osal_nonos_indp
ifeq ($(BUILD_OS_TYPE),tirtos)
osal_LIB_LIST += osal_tirtos osal_tirtos_indp
endif
libosal_LIB_LIST = $(osal_LIB_LIST)

############################
# osal examples
# List of examples under osal
# All the tests mentioned in list are built when test target is called
# List below all examples for allowed values
############################
osal_EXAMPLE_LIST =

#
# OSAL Modules
#

# OSAL NONOS LIB
osal_nonos_COMP_LIST = osal_nonos
osal_nonos_RELPATH = ti/osal
osal_nonos_PATH = $(PDK_OSAL_COMP_PATH)
osal_nonos_LIBNAME = ti.osal
export osal_nonos_LIBNAME
osal_nonos_LIBPATH = $(osal_nonos_PATH)/lib/nonos
export osal_nonos_LIBPATH
osal_nonos_OBJPATH = $(osal_nonos_RELPATH)/osal_nonos
export osal_nonos_OBJPATH
osal_nonos_MAKEFILE = -f build/makefile_nonos.mk
export osal_nonos_MAKEFILE
osal_nonos_PLATFORM_DEPENDENCY = no
osal_nonos_CORE_DEPENDENCY = no
osal_nonos_SOC_DEPENDENCY = yes
export osal_nonos_COMP_LIST
export osal_nonos_PLATFORM_DEPENDENCY
export osal_nonos_CORE_DEPENDENCY
export osal_nonos_SOC_DEPENDENCY
osal_nonos_PKG_LIST = osal_nonos
export osal_nonos_PKG_LIST
osal_nonos_INCLUDE = $(osal_nonos_PATH)
osal_nonos_SOCLIST = $(libosal_SOCLIST)
export osal_nonos_SOCLIST
osal_nonos_$(SOC)_CORELIST = $(libosal_$(SOC)_CORELIST)
export osal_nonos_$(SOC)_CORELIST

# OSAL NONOS LIB DEVICE INDEPENDENT
osal_nonos_indp_COMP_LIST = osal_nonos_indp
osal_nonos_indp_RELPATH = ti/osal
osal_nonos_indp_PATH = $(PDK_OSAL_COMP_PATH)
osal_nonos_indp_LIBNAME = ti.osal
export osal_nonos_indp_LIBNAME
osal_nonos_indp_LIBPATH = $(osal_nonos_indp_PATH)/lib/nonos
export osal_nonos_indp_LIBPATH
osal_nonos_indp_OBJPATH = $(osal_nonos_indp_RELPATH)/osal_nonos_indp
export osal_nonos_indp_OBJPATH
osal_nonos_indp_MAKEFILE = -f build/makefile_nonos_indp.mk
export osal_nonos_indp_MAKEFILE
osal_nonos_indp_PLATFORM_DEPENDENCY = no
osal_nonos_indp_CORE_DEPENDENCY = no
osal_nonos_indp_SOC_DEPENDENCY = no
export osal_nonos_indp_COMP_LIST
export osal_nonos_indp_PLATFORM_DEPENDENCY
export osal_nonos_indp_CORE_DEPENDENCY
export osal_nonos_indp_SOC_DEPENDENCY
osal_nonos_indp_PKG_LIST = osal_nonos_indp
export osal_nonos_indp_PKG_LIST
osal_nonos_indp_INCLUDE = $(osal_nonos_indp_PATH)
osal_nonos_indp_SOCLIST = $(libosal_SOCLIST)
export osal_nonos_indp_SOCLIST
osal_nonos_indp_$(SOC)_CORELIST = $(libosal_$(SOC)_CORELIST)
export osal_nonos_indp_$(SOC)_CORELIST

# OSAL TIRTOS LIB
osal_tirtos_COMP_LIST = osal_tirtos
osal_tirtos_RELPATH = ti/osal
osal_tirtos_PATH = $(PDK_OSAL_COMP_PATH)
osal_tirtos_LIBNAME = ti.osal
export osal_tirtos_LIBNAME
osal_tirtos_LIBPATH = $(osal_tirtos_PATH)/lib/tirtos
export osal_tirtos_LIBPATH
osal_tirtos_OBJPATH = $(osal_tirtos_RELPATH)/osal_tirtos
export osal_tirtos_OBJPATH
osal_tirtos_MAKEFILE = -f build/makefile_tirtos.mk
export osal_tirtos_MAKEFILE
osal_tirtos_PLATFORM_DEPENDENCY = no
osal_tirtos_CORE_DEPENDENCY = no
osal_tirtos_SOC_DEPENDENCY = yes
export osal_tirtos_COMP_LIST
export osal_tirtos_PLATFORM_DEPENDENCY
export osal_tirtos_CORE_DEPENDENCY
export osal_tirtos_SOC_DEPENDENCY
osal_tirtos_PKG_LIST = osal_tirtos
export osal_tirtos_PKG_LIST
osal_tirtos_INCLUDE = $(osal_tirtos_PATH)
osal_tirtos_SOCLIST = $(libosal_SOCLIST)
export osal_tirtos_SOCLIST
osal_tirtos_$(SOC)_CORELIST = $(libosal_$(SOC)_CORELIST)
export osal_tirtos_$(SOC)_CORELIST

# OSAL TIRTOS DEVICE INDEPENDENT
osal_tirtos_indp_COMP_LIST = osal_tirtos_indp
osal_tirtos_indp_RELPATH = ti/osal
osal_tirtos_indp_PATH = $(PDK_OSAL_COMP_PATH)
osal_tirtos_indp_LIBNAME = ti.osal
export osal_tirtos_indp_LIBNAME
osal_tirtos_indp_LIBPATH = $(osal_tirtos_indp_PATH)/lib/tirtos
export osal_tirtos_indp_LIBPATH
osal_tirtos_indp_OBJPATH = $(osal_tirtos_indp_RELPATH)/osal_tirtos_indp
export osal_tirtos_indp_OBJPATH
osal_tirtos_indp_MAKEFILE = -f build/makefile_tirtos_indp.mk
export osal_tirtos_indp_MAKEFILE
osal_tirtos_indp_PLATFORM_DEPENDENCY = no
osal_tirtos_indp_CORE_DEPENDENCY = no
osal_tirtos_indp_SOC_DEPENDENCY = no
export osal_tirtos_indp_COMP_LIST
export osal_tirtos_indp_PLATFORM_DEPENDENCY
export osal_tirtos_indp_CORE_DEPENDENCY
export osal_tirtos_indp_SOC_DEPENDENCY
osal_tirtos_indp_PKG_LIST = osal_tirtos_indp
export osal_tirtos_indp_PKG_LIST
osal_tirtos_indp_INCLUDE = $(osal_tirtos_indp_PATH)
osal_tirtos_indp_SOCLIST = $(libosal_SOCLIST)
export osal_tirtos_indp_SOCLIST
osal_tirtos_indp_$(SOC)_CORELIST = $(libosal_$(SOC)_CORELIST)
export osal_tirtos_indp_$(SOC)_CORELIST

#
# OSAL Examples
#
OSAL_Baremetal_TestApp_COMP_LIST = OSAL_Baremetal_TestApp
OSAL_Baremetal_TestApp_RELPATH = ti/osal/test/baremetal
OSAL_Baremetal_TestApp_PATH = $(PDK_OSAL_COMP_PATH)/test/baremetal
OSAL_Baremetal_TestApp_BOARD_DEPENDENCY = yes
OSAL_Baremetal_TestApp_CORE_DEPENDENCY = no
export OSAL_Baremetal_TestApp_COMP_LIST
export OSAL_Baremetal_TestApp_BOARD_DEPENDENCY
export OSAL_Baremetal_TestApp_CORE_DEPENDENCY
OSAL_Baremetal_TestApp_PKG_LIST = OSAL_Baremetal_TestApp
OSAL_Baremetal_TestApp_INCLUDE = $(OSAL_Baremetal_TestApp_PATH)
OSAL_Baremetal_TestApp_BOARDLIST = $(libosal_BOARDLIST)
export OSAL_Baremetal_TestApp_BOARDLIST

OSAL_Baremetal_TestApp_SBL_APPIMAGEGEN = yes
export OSAL_Baremetal_TestApp_SBL_APPIMAGEGEN

# OSAL sysbios unit test app
OSAL_TestApp_COMP_LIST = OSAL_TestApp
OSAL_TestApp_RELPATH = ti/osal/test/sysbios_unit_test
OSAL_TestApp_PATH = $(PDK_OSAL_COMP_PATH)/test/sysbios_unit_test
OSAL_TestApp_BOARD_DEPENDENCY = yes
OSAL_TestApp_CORE_DEPENDENCY = no
OSAL_TestApp_XDC_CONFIGURO = yes
export OSAL_TestApp_COMP_LIST
export OSAL_TestApp_BOARD_DEPENDENCY
export OSAL_TestApp_CORE_DEPENDENCY
export OSAL_TestApp_XDC_CONFIGURO
OSAL_TestApp_PKG_LIST = OSAL_TestApp
OSAL_TestApp_INCLUDE = $(OSAL_TestApp_PATH)
OSAL_TestApp_BOARDLIST = $(libosal_BOARDLIST)
export OSAL_TestApp_BOARDLIST
OSAL_TestApp_$(SOC)_CORELIST = $(osal_$(SOC)_CORELIST)
export OSAL_TestApp_$(SOC)_CORELIST

OSAL_TestApp_SBL_APPIMAGEGEN = yes
export OSAL_TestApp_SBL_APPIMAGEGEN

#Default Core List
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = a15_0 c66x

# Overwrite default core list for below SoCs
ifeq ($(BOARD),$(filter $(BOARD), idkAM574x evmAM572x idkAM572x idkAM571x))
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = a15_0 ipu1_0 c66x
endif

ifeq ($(BOARD),$(filter $(BOARD), evmAM335x))
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = a8host
endif


ifeq ($(BOARD),$(filter $(BOARD), evmAM437x idkAM437x))
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = a9host
endif

ifeq ($(BOARD),$(filter $(BOARD), evmOMAPL137))
osal_baremetal_test_$(SOC)_CORELIST = c674x arm9_0
endif

ifeq ($(BOARD),$(filter $(BOARD), lcdkOMAPL138))
osal_baremetal_test_$(SOC)_CORELIST = c674x arm9_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2E))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2H evmK2K))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2L))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmOMAPL137))
osal_baremetal_test_$(SOC)_CORELIST = c674x arm9_0
endif

ifeq ($(BOARD),$(filter $(BOARD), lcdkOMAPL138))
osal_baremetal_test_$(SOC)_CORELIST = c674x arm9_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2E))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2H evmK2K))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2L))
osal_baremetal_test_$(SOC)_CORELIST = c66x a15_0
endif

ifeq ($(SOC),$(filter $(SOC), dra72x dra75x))
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = a15_0 ipu1_0 c66x
endif

ifeq ($(SOC),$(filter $(SOC), dra78x))
OSAL_Baremetal_TestApp_$(SOC)_CORELIST = ipu1_0 c66x
endif


ifeq ($(SOC),$(filter $(SOC), am65xx))
 OSAL_TestApp_$(SOC)_CORELIST = mpu1_0 mcu1_0
 OSAL_Baremetal_TestApp_$(SOC)_CORELIST = mpu1_0 mcu1_0
endif

ifeq ($(SOC),$(filter $(SOC), j721e))
	OSAL_TestApp_$(SOC)_CORELIST = mpu1_0 mcu1_0 mcu2_0 mcu3_0 c66xdsp_1 c7x_1
 OSAL_Baremetal_TestApp_$(SOC)_CORELIST = mpu1_0 mcu1_0 mcu2_0 mcu3_0
endif

export OSAL_Baremetal_TestApp_$(SOC)_CORELIST
export OSAL_TestApp_$(SOC)_CORELIST

osal_EXAMPLE_LIST += OSAL_Baremetal_TestApp
osal_EXAMPLE_LIST += OSAL_TestApp


ifeq ($(CPLUSPLUS_BUILD), yes)
#cpptest
cpptest_COMP_LIST = cpptest
cpptest_RELPATH = ti/osal/test/cpptest
cpptest_PATH = $(PDK_OSAL_COMP_PATH)/test/cpptest
cpptest_BOARD_DEPENDENCY = yes
cpptest_CORE_DEPENDENCY = yes
export cpptest_COMP_LIST
export cpptest_BOARD_DEPENDENCY
export cpptest_CORE_DEPENDENCY
cpptest_PKG_LIST = cpptest
cpptest_INCLUDE = $(cpptest_PATH)
cpptest_BOARDLIST = $(libosal_BOARDLIST)
export cpptest_BOARDLIST

#Default Core List
ifeq ($(BOARD),$(filter $(BOARD), evmAM335x))
cpptest_$(SOC)_CORELIST = a8host
endif

ifeq ($(BOARD),$(filter $(BOARD), evmAM437x idkAM437x))
cpptest_$(SOC)_CORELIST = a9host
endif

ifeq ($(BOARD),$(filter $(BOARD), idkAM574x evmAM572x idkAM572x idkAM571x))
cpptest_$(SOC)_CORELIST = a15_0 ipu1_0 c66x
endif

ifeq ($(BOARD),$(filter $(BOARD), evmK2G iceK2G))
cpptest_$(SOC)_CORELIST = c66x a15_0
endif

export cpptest_$(SOC)_CORELIST
osal_EXAMPLE_LIST += cpptest
endif

export osal_LIB_LIST
export libosal_LIB_LIST
export osal_EXAMPLE_LIST

libosal_EXAMPLE_LIST = $(osal_EXAMPLE_LIST)
export libosal_EXAMPLE_LIST

osal_component_make_include := 1
endif