1 #
2 # Copyright (c) 2018, Texas Instruments Incorporated
3 # All rights reserved.
4 #
5 # Redistribution and use in source and binary forms, with or without
6 # modification, are permitted provided that the following conditions
7 # are met:
8 #
9 # * Redistributions of source code must retain the above copyright
10 # notice, this list of conditions and the following disclaimer.
11 #
12 # * Redistributions in binary form must reproduce the above copyright
13 # notice, this list of conditions and the following disclaimer in the
14 # documentation and/or other materials provided with the distribution.
15 #
16 # * Neither the name of Texas Instruments Incorporated nor the names of
17 # its contributors may be used to endorse or promote products derived
18 # from this software without specific prior written permission.
19 #
20 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21 # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22 # THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23 # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24 # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25 # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26 # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27 # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28 # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29 # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30 # EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 #
33 # File: sbl_component.mk
34 # This file is component include make file of SBL.
35 # List of variables set in this file and their purpose:
36 # <mod>_RELPATH - This is the relative path of the module, typically from
37 # top-level directory of the package
38 # <mod>_PATH - This is the absolute path of the module. It derives from
39 # absolute path of the top-level directory (set in env.mk)
40 # and relative path set above
41 # <mod>_INCLUDE - This is the path that has interface header files of the
42 # module. This can be multiple directories (space separated)
43 # <mod>_PKG_LIST - Names of the modules (and sub-modules) that are a part
44 # part of this module, including itself.
45 # <mod>_BOARD_DEPENDENCY - "yes": means the code for this module depends on
46 # platform and the compiled obj/lib has to be kept
47 # under <platform> directory
48 # "no" or "" or if this variable is not defined: means
49 # this module has no platform dependent code and hence
50 # the obj/libs are not kept under <platform> dir.
51 # <mod>_CORE_DEPENDENCY - "yes": means the code for this module depends on
52 # core and the compiled obj/lib has to be kept
53 # under <core> directory
54 # "no" or "" or if this variable is not defined: means
55 # this module has no core dependent code and hence
56 # the obj/libs are not kept under <core> dir.
57 # <mod>_APP_STAGE_FILES - List of source files that belongs to the module
58 # <mod>, but that needs to be compiled at application
59 # build stage (in the context of the app). This is
60 # primarily for link time configurations or if the
61 # source file is dependent on options/defines that are
62 # application dependent. This can be left blank or
63 # not defined at all, in which case, it means there
64 # no source files in the module <mod> that are required
65 # to be compiled in the application build stage.
66 #
67 ifeq ($(sbl_component_make_include), )
69 sbl_BOARDLIST = am65xx_evm am65xx_idk j721e_sim
71 sbl_SOCLIST = am65xx j721e
73 am65xx_smp_CORELIST := mcu1_0 mpu1_0 mpu2_0
74 sbl_am65xx_CORELIST := mcu1_0 mcu1_1 mpu1_0 mpu1_1 mpu2_0 mpu2_1
75 am65xx_LASTCORE := $(word $(words $(sbl_am65xx_CORELIST)), $(sbl_am65xx_CORELIST))
77 j721e_smp_CORELIST := mcu1_0 mcu2_0 mcu3_0 mpu1_0
78 sbl_j721e_CORELIST := mcu1_0 mcu1_1 mcu2_0 mcu2_1 mcu3_0 mcu3_1 mpu1_0 mpu1_1
79 j721e_LASTCORE := $(word $(words $(sbl_j721e_CORELIST)), $(sbl_j721e_CORELIST))
81 sbl_DISABLE_PARALLEL_MAKE = yes
82 ############################
83 # sbl package
84 # List of components included under sbl
85 # The components included here are built and will be part of sbl
86 ############################
87 sbl_LIB_LIST = sbl_lib_mmcsd sbl_lib_ospi sbl_lib_cust
89 ############################
90 # sbl example
91 # List of examples under sbl (+= is used at each example definition)
92 # All the tests mentioned in list are built when test target is called
93 # List below all examples for allowed values
94 ############################
95 sbl_EXAMPLE_LIST =
97 #
98 # SBL Modules
99 #
101 # SBL MMCSD LIB
102 sbl_lib_mmcsd_COMP_LIST = sbl_lib_mmcsd
103 sbl_lib_mmcsd_RELPATH = ti/boot/sbl
104 export sbl_lib_mmcsd_OBJPATH = ti/boot/sbl/mmcsd
105 sbl_lib_mmcsd_PATH = $(PDK_SBL_COMP_PATH)
106 sbl_lib_mmcsd_LIBNAME = sbl_lib_mmcsd
107 sbl_lib_mmcsd_LIBPATH = $(PDK_SBL_COMP_PATH)/lib/mmcsd
108 sbl_lib_mmcsd_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_lib.mk BOOTMODE=mmcsd
109 export sbl_lib_mmcsd_MAKEFILE
110 export sbl_lib_mmcsd_LIBNAME
111 export sbl_lib_mmcsd_LIBPATH
112 sbl_lib_mmcsd_BOARD_DEPENDENCY = yes
113 sbl_lib_mmcsd_SOC_DEPENDENCY = yes
114 sbl_lib_mmcsd_CORE_DEPENDENCY = no
115 export sbl_lib_mmcsd_COMP_LIST
116 export sbl_lib_mmcsd_BOARD_DEPENDENCY
117 export sbl_lib_mmcsd_CORE_DEPENDENCY
118 sbl_lib_mmcsd_PKG_LIST = sbl_lib_mmcsd
119 sbl_lib_mmcsd_INCLUDE = $(sbl_lib_mmcsd_PATH)
120 sbl_lib_mmcsd_SOCLIST = $(sbl_SOCLIST)
121 sbl_lib_mmcsd_BOARDLIST = $(sbl_BOARDLIST)
122 export sbl_lib_mmcsd_SOCLIST
123 export sbl_lib_mmcsd_BOARDLIST
124 sbl_lib_mmcsd_$(SOC)_CORELIST = mcu1_0
125 export sbl_lib_mmcsd_$(SOC)_CORELIST
127 # SBL OSPI LIB
128 sbl_lib_ospi_COMP_LIST = sbl_lib_ospi
129 sbl_lib_ospi_RELPATH = ti/boot/sbl/ospi
130 export sbl_lib_ospi_OBJPATH = ti/boot/sbl/ospi
131 sbl_lib_ospi_PATH = $(PDK_SBL_COMP_PATH)
132 sbl_lib_ospi_LIBNAME = sbl_lib_ospi
133 sbl_lib_ospi_LIBPATH = $(PDK_SBL_COMP_PATH)/lib/ospi
134 sbl_lib_ospi_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_lib.mk BOOTMODE=ospi
135 export sbl_lib_ospi_MAKEFILE
136 export sbl_lib_ospi_LIBNAME
137 export sbl_lib_ospi_LIBPATH
138 sbl_lib_ospi_BOARD_DEPENDENCY = yes
139 sbl_lib_ospi_SOC_DEPENDENCY = yes
140 sbl_lib_ospi_CORE_DEPENDENCY = no
141 export sbl_lib_ospi_COMP_LIST
142 export sbl_lib_ospi_BOARD_DEPENDENCY
143 export sbl_lib_ospi_CORE_DEPENDENCY
144 sbl_lib_ospi_PKG_LIST = sbl_lib_ospi
145 sbl_lib_ospi_INCLUDE = $(sbl_lib_ospi_PATH)
146 sbl_lib_ospi_SOCLIST = am65xx
147 sbl_lib_ospi_BOARDLIST = am65xx_evm am65xx_idk
148 export sbl_lib_ospi_SOCLIST
149 export sbl_lib_ospi_BOARDLIST
150 sbl_lib_ospi_$(SOC)_CORELIST = mcu1_0
151 export sbl_lib_ospi_$(SOC)_CORELIST
153 #
154 # SBL Examples
155 #
156 # SBL MMCSD Image
157 sbl_mmcsd_img_COMP_LIST = sbl_mmcsd_img
158 sbl_mmcsd_img_RELPATH = ti/boot/sbl/board/k3
159 sbl_mmcsd_img_CUSTOM_BINPATH = $(PDK_SBL_COMP_PATH)/binary/$(BOARD)/mmcsd/bin
160 sbl_mmcsd_img_PATH = $(PDK_SBL_COMP_PATH)/board/k3
161 sbl_mmcsd_img_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_img.mk BOOTMODE=mmcsd
162 export sbl_mmcsd_img_MAKEFILE
163 sbl_mmcsd_img_BOARD_DEPENDENCY = yes
164 sbl_mmcsd_img_SOC_DEPENDENCY = yes
165 sbl_mmcsd_img_CORE_DEPENDENCY = no
166 export sbl_mmcsd_img_COMP_LIST
167 export sbl_mmcsd_img_BOARD_DEPENDENCY
168 export sbl_mmcsd_img_SOC_DEPENDENCY
169 export sbl_mmcsd_img_CORE_DEPENDENCY
170 sbl_mmcsd_img_PKG_LIST = sbl
171 sbl_mmcsd_img_INCLUDE = $(sbl_mmcsd_img_PATH)
172 sbl_mmcsd_img_BOARDLIST = $(sbl_BOARDLIST)
173 export sbl_mmcsd_img_BOARDLIST
174 sbl_mmcsd_img_$(SOC)_CORELIST = mcu1_0
175 export sbl_mmcsd_img_$(SOC)_CORELIST
176 sbl_EXAMPLE_LIST += sbl_mmcsd_img
177 sbl_mmcsd_img_SBL_IMAGEGEN = yes
178 export sbl_mmcsd_img_SBL_IMAGEGEN
180 # SBL OSPI Image
181 sbl_ospi_img_COMP_LIST = sbl_ospi_img
182 sbl_ospi_img_RELPATH = ti/boot/sbl/board/k3
183 sbl_ospi_img_CUSTOM_BINPATH = $(PDK_SBL_COMP_PATH)/binary/$(BOARD)/ospi/bin
184 sbl_ospi_img_PATH = $(PDK_SBL_COMP_PATH)/board/k3
185 sbl_ospi_img_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_img.mk BOOTMODE=ospi
186 export sbl_ospi_img_MAKEFILE
187 sbl_ospi_img_BOARD_DEPENDENCY = yes
188 sbl_ospi_img_SOC_DEPENDENCY = yes
189 sbl_ospi_img_CORE_DEPENDENCY = no
190 export sbl_ospi_img_COMP_LIST
191 export sbl_ospi_img_BOARD_DEPENDENCY
192 export sbl_ospi_img_SOC_DEPENDENCY
193 export sbl_ospi_img_CORE_DEPENDENCY
194 sbl_ospi_img_PKG_LIST = sbl
195 sbl_ospi_img_INCLUDE = $(sbl_ospi_img_PATH)
196 sbl_ospi_img_BOARDLIST = am65xx_evm am65xx_idk
197 export sbl_ospi_img_BOARDLIST
198 sbl_ospi_img_$(SOC)_CORELIST = mcu1_0
199 export sbl_ospi_img_$(SOC)_CORELIST
200 sbl_EXAMPLE_LIST += sbl_ospi_img
201 sbl_ospi_img_SBL_IMAGEGEN = yes
202 export sbl_ospi_img_SBL_IMAGEGEN
204 # Individual Core Boot Test
205 sbl_boot_test_COMP_LIST = sbl_boot_test
206 sbl_boot_test_RELPATH = ti/boot/sbl/example/k3MulticoreApp
207 sbl_boot_test_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
208 sbl_boot_test_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
209 sbl_boot_test_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_boot_test.mk
210 export sbl_boot_test_MAKEFILE
211 sbl_boot_test_BOARD_DEPENDENCY = no
212 sbl_boot_test_SOC_DEPENDENCY = no
213 sbl_boot_test_CORE_DEPENDENCY = no
214 export sbl_boot_test_COMP_LIST
215 export sbl_boot_test_BOARD_DEPENDENCY
216 export sbl_boot_test_SOC_DEPENDENCY
217 export sbl_boot_test_CORE_DEPENDENCY
218 sbl_boot_test_PKG_LIST = sbl_boot_test
219 sbl_boot_test_INCLUDE = $(sbl_boot_test_PATH)
220 sbl_boot_test_BOARDLIST = $(sbl_BOARDLIST)
221 export sbl_boot_test_BOARDLIST
222 sbl_boot_test_$(SOC)_CORELIST = $(sbl_$(SOC)_CORELIST)
223 export sbl_boot_test_$(SOC)_CORELIST
224 sbl_EXAMPLE_LIST += sbl_boot_test
225 sbl_boot_test_SBL_APPIMAGEGEN = yes
226 ifeq ($(SOC),$(filter $(SOC), j721e))
227 sbl_boot_test_SBL_APPIMAGEGEN = no
228 endif
229 export sbl_boot_test_SBL_APPIMAGEGEN
231 # Multicore AMP Boot Test
232 sbl_multicore_amp_COMP_LIST = sbl_multicore_amp
233 sbl_multicore_amp_RELPATH = ti/boot/sbl/example/k3MulticoreApp
234 sbl_multicore_amp_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
235 sbl_multicore_amp_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
236 sbl_multicore_amp_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_multicore_amp.mk
237 export sbl_multicore_amp_MAKEFILE
238 sbl_multicore_amp_BOARD_DEPENDENCY = no
239 sbl_multicore_amp_SOC_DEPENDENCY = no
240 sbl_multicore_amp_CORE_DEPENDENCY = no
241 export sbl_multicore_amp_COMP_LIST
242 export sbl_multicore_amp_BOARD_DEPENDENCY
243 export sbl_multicore_amp_SOC_DEPENDENCY
244 export sbl_multicore_amp_CORE_DEPENDENCY
245 sbl_multicore_amp_PKG_LIST = sbl_multicore_amp
246 sbl_multicore_amp_INCLUDE = $(sbl_multicore_amp_PATH)
247 sbl_multicore_amp_BOARDLIST = $(sbl_BOARDLIST)
248 export sbl_multicore_amp_BOARDLIST
249 sbl_multicore_amp_$(SOC)_CORELIST = $($(SOC)_LASTCORE)
250 export sbl_multicore_amp_$(SOC)_CORELIST
251 sbl_EXAMPLE_LIST += sbl_multicore_amp
252 sbl_multicore_amp_SBL_APPIMAGEGEN = no
253 export sbl_multicore_amp_SBL_APPIMAGEGEN
255 # R5 Lockstep and MPU SMP Boot Test
256 sbl_smp_test_COMP_LIST = sbl_smp_test
257 sbl_smp_test_RELPATH = ti/boot/sbl/example/k3MulticoreApp
258 sbl_smp_test_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
259 sbl_smp_test_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
260 sbl_smp_test_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_smp_test.mk BOOTMODE=mmcsd
261 export sbl_smp_test_MAKEFILE
262 sbl_smp_test_BOARD_DEPENDENCY = no
263 sbl_smp_test_SOC_DEPENDENCY = no
264 sbl_smp_test_CORE_DEPENDENCY = no
265 export sbl_smp_test_COMP_LIST
266 export sbl_smp_test_BOARD_DEPENDENCY
267 export sbl_smp_test_SOC_DEPENDENCY
268 export sbl_smp_test_CORE_DEPENDENCY
269 sbl_smp_test_PKG_LIST = sbl_smp_test
270 sbl_smp_test_INCLUDE = $(sbl_smp_test_PATH)
271 sbl_smp_test_BOARDLIST = $(sbl_BOARDLIST)
272 export sbl_smp_test_BOARDLIST
273 sbl_smp_test_$(SOC)_CORELIST = $($(SOC)_smp_CORELIST)
274 export sbl_smp_test_$(SOC)_CORELIST
275 sbl_EXAMPLE_LIST += sbl_smp_test
276 sbl_smp_test_SBL_APPIMAGEGEN = yes
277 ifeq ($(SOC),$(filter $(SOC), j721e))
278 sbl_smp_test_SBL_APPIMAGEGEN = no
279 endif
280 export sbl_smp_test_SBL_APPIMAGEGEN
282 # Multicore SMP Boot Test
283 sbl_multicore_smp_COMP_LIST = sbl_multicore_smp
284 sbl_multicore_smp_RELPATH = ti/boot/sbl/example/k3MulticoreApp
285 sbl_multicore_smp_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
286 sbl_multicore_smp_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
287 sbl_multicore_smp_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_multicore_smp.mk
288 export sbl_multicore_smp_MAKEFILE
289 sbl_multicore_smp_BOARD_DEPENDENCY = no
290 sbl_multicore_smp_SOC_DEPENDENCY = no
291 sbl_multicore_smp_CORE_DEPENDENCY = no
292 export sbl_multicore_smp_COMP_LIST
293 export sbl_multicore_smp_BOARD_DEPENDENCY
294 export sbl_multicore_smp_SOC_DEPENDENCY
295 export sbl_multicore_smp_CORE_DEPENDENCY
296 sbl_multicore_smp_PKG_LIST = sbl_multicore_smp
297 sbl_multicore_smp_INCLUDE = $(sbl_multicore_smp_PATH)
298 sbl_multicore_smp_BOARDLIST = $(sbl_BOARDLIST)
299 export sbl_multicore_smp_BOARDLIST
300 sbl_multicore_smp_$(SOC)_CORELIST := $($(SOC)_LASTCORE)
301 export sbl_multicore_smp_$(SOC)_CORELIST
302 sbl_EXAMPLE_LIST += sbl_multicore_smp
303 sbl_multicore_smp_SBL_APPIMAGEGEN = no
304 export sbl_multicore_smp_SBL_APPIMAGEGEN
306 # 0 - use cpu for reads (slower, no $ coherency ops needed), smaller SBL
307 # 1 - use dma for data reads (faster, $ coherency ops needed), larger SBL
308 SBL_CFLAGS = -DSBL_USE_DMA=1
310 # R5 boot XIP Test
311 sbl_boot_xip_test_COMP_LIST = sbl_boot_xip_test
312 sbl_boot_xip_test_RELPATH = ti/boot/sbl/example/k3MulticoreApp
313 sbl_boot_xip_test_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
314 sbl_boot_xip_test_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
315 sbl_boot_xip_test_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_mcu0_boot_xip_test.mk
316 export sbl_boot_xip_test_MAKEFILE
317 sbl_boot_xip_test_BOARD_DEPENDENCY = no
318 sbl_boot_xip_test_SOC_DEPENDENCY = no
319 sbl_boot_xip_test_CORE_DEPENDENCY = no
320 export sbl_boot_xip_test_COMP_LIST
321 export sbl_boot_xip_test_BOARD_DEPENDENCY
322 export sbl_boot_xip_test_SOC_DEPENDENCY
323 export sbl_boot_xip_test_CORE_DEPENDENCY
324 sbl_boot_xip_test_PKG_LIST = sbl_boot_xip_test
325 sbl_boot_xip_test_INCLUDE = $(sbl_boot_xip_test_PATH)
326 sbl_boot_xip_test_BOARDLIST = $(sbl_BOARDLIST)
327 export sbl_boot_xip_test_BOARDLIST
328 sbl_boot_xip_test_$(SOC)_CORELIST = mcu1_0
329 export sbl_boot_xip_test_$(SOC)_CORELIST
330 sbl_EXAMPLE_LIST += sbl_boot_xip_test
331 sbl_boot_xip_test_SBL_APPIMAGEGEN = yes
332 sbl_boot_xip_test_SBL_APP_BINIMAGEGEN = yes
333 sbl_boot_xip_test_SBL_APP_BIN_SECTIONS = --only-section .rstvectors --only-section .sbl_mcu_1_0_resetvector
334 ifeq ($(SOC),$(filter $(SOC), j721e))
335 sbl_boot_xip_test_SBL_APPIMAGEGEN = no
336 sbl_boot_xip_test_SBL_APP_BINIMAGEGEN = no
337 endif
338 export sbl_boot_xip_test_SBL_APPIMAGEGEN
339 export sbl_boot_xip_test_SBL_APP_BINIMAGEGEN
340 export sbl_boot_xip_test_SBL_APP_BIN_SECTIONS
342 # R5 boot XIP entry
343 sbl_boot_xip_entry_COMP_LIST = sbl_boot_xip_entry
344 sbl_boot_xip_entry_RELPATH = ti/boot/sbl/example/k3MulticoreApp
345 sbl_boot_xip_entry_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
346 sbl_boot_xip_entry_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
347 sbl_boot_xip_entry_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_mcu0_boot_xip_entry.mk
348 export sbl_boot_xip_entry_MAKEFILE
349 sbl_boot_xip_entry_BOARD_DEPENDENCY = no
350 sbl_boot_xip_entry_SOC_DEPENDENCY = no
351 sbl_boot_xip_entry_CORE_DEPENDENCY = no
352 export sbl_boot_xip_entry_COMP_LIST
353 export sbl_boot_xip_entry_BOARD_DEPENDENCY
354 export sbl_boot_xip_entry_SOC_DEPENDENCY
355 export sbl_boot_xip_entry_CORE_DEPENDENCY
356 sbl_boot_xip_entry_PKG_LIST = sbl_boot_xip_entry
357 sbl_boot_xip_entry_INCLUDE = $(sbl_boot_xip_entry_PATH)
358 sbl_boot_xip_entry_BOARDLIST = $(sbl_BOARDLIST)
359 export sbl_boot_xip_entry_BOARDLIST
360 sbl_boot_xip_entry_$(SOC)_CORELIST = mcu1_0
361 export sbl_boot_xip_entry_$(SOC)_CORELIST
362 sbl_EXAMPLE_LIST += sbl_boot_xip_entry
363 sbl_boot_xip_entry_SBL_APPIMAGEGEN = yes
364 ifeq ($(SOC),$(filter $(SOC), j721e))
365 sbl_boot_xip_entry_SBL_APPIMAGEGEN = no
366 endif
367 export sbl_boot_xip_entry_SBL_APPIMAGEGEN
369 # Display profiling info before MCU1_0 boot
370 # increases delay time, between end of SBL
371 # and start of app, but useful for
372 # debugging and tuning performace knobs
373 #SBL_CFLAGS += -DSBL_DISPLAY_PROFILE_INFO
375 ###### Use boot_perf_benchmark example#######
376 ###### to fine tune the perf knobs #########
378 ###########START BOOT PERF KNOBS#############
379 # SBL log level
380 # no logs = 0, only errors =1, normal logs = 2, all logs = 3
381 SBL_CFLAGS += -DSBL_LOG_LEVEL=2
383 SBL_CFLAGS += -DSBL_ENABLE_PLL
384 SBL_CFLAGS += -DSBL_ENABLE_CLOCKS
385 SBL_CFLAGS += -DSBL_ENABLE_DDR
387 ############################################
388 # DISABLING the options above this caption
389 # improves boot time at the cost of moving
390 # PLL, LPSC and DDR init to the app
391 #
392 # ENABLING the options below this caption
393 # improves boot time by skipping stuff SBL
394 # usually does.
395 ###########################################
396 # If enabled, the SBL will branch to the start
397 # of MCU_0 app without resetting the core
398 # if csl defaults are godd enough this enables
399 # app to skip redoing mcu initialization
400 #SBL_CFLAGS += -DSBL_SKIP_MCU_RESET
402 # If enabled, SBL will skip initializing
403 # sysfw. The SBL will only load it.
404 # No SCI Client APIs will work. Saves
405 # boot time. When this is enabled
406 # make sure that SBL_SKIP_MCU_RESET is also
407 # enabled, as resetting a core needs SYSFW
408 # to be running.
409 # SBL_CFLAGS += -DSBL_SKIP_SYSFW_INIT
411 # If enabled, SBL will skip calling
412 # Sciclient_boardCfg* API. Enabling
413 # it saves boot time, can affect
414 # functionality. The app must call the
415 # Sciclient_boardCfg* APIs that the SBL
416 # skips. Like for eg, if SBL skips calling
417 # Sciclient_boardCfgPm, the UART_printf will
418 # get garbled, adn teh app must call
419 # Sciclient_boardCfgPm to have UART_printf
420 # workign again
421 #to work again.
422 #SBL_CFLAGS += -DSBL_SKIP_BRD_CFG_BOARD
423 #SBL_CFLAGS += -DSBL_SKIP_BRD_CFG_RM
424 #SBL_CFLAGS += -DSBL_SKIP_BRD_CFG__SEC
425 #SBL_CFLAGS += -DSBL_SKIP_BRD_CFG_PM
427 ###########END BOOT PERF KNOBS#############
429 # Example - Building Custom SBL Images
430 # Build and SBl with custom flags to change
431 # different build configurations
432 CUST_SBL_TEST_SOCS = am65xx
433 CUST_SBL_TEST_BOARDS = am65xx_evm
434 #CUST_SBL_TEST_FLAGS =" -DSBL_USE_DMA=1 -DSBL_LOG_LEVEL=0 -DSBL_SCRATCH_MEM_START=0x70100000 -DSBL_SKIP_MCU_RESET -DSBL_SKIP_BRD_CFG_PM -DBOOT_OSPI "
435 #CUST_SBL_TEST_FLAGS =" -DSBL_USE_DMA=0 -DSBL_LOG_LEVEL=0 -DSBL_SCRATCH_MEM_START=0x70100000 -DSBL_SCRATCH_MEM_SIZE=0xF0000 -DSBL_SKIP_SYSFW_INIT -DSBL_SKIP_MCU_RESET -DBOOT_OSPI"
436 CUST_SBL_TEST_FLAGS =" -DSBL_USE_DMA=0 -DSBL_LOG_LEVEL=1 -DSBL_SCRATCH_MEM_START=0x70100000 -DSBL_SCRATCH_MEM_SIZE=0xF0000 -DSBL_ENABLE_PLL -DSBL_ENABLE_CLOCKS -DSBL_SKIP_MCU_RESET -DBOOT_OSPI"
438 # SBL Custom LIB
439 sbl_lib_cust_COMP_LIST = sbl_lib_cust
440 sbl_lib_cust_RELPATH = ti/boot/sbl
441 export sbl_lib_cust_OBJPATH = ti/boot/sbl/cust
442 sbl_lib_cust_PATH = $(PDK_SBL_COMP_PATH)
443 sbl_lib_cust_LIBNAME = sbl_lib_cust
444 sbl_lib_cust_LIBPATH = $(PDK_SBL_COMP_PATH)/lib/cust
445 sbl_lib_cust_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_lib.mk BOOTMODE=cust CUST_SBL_FLAGS=$(CUST_SBL_TEST_FLAGS)
446 export sbl_lib_cust_MAKEFILE
447 export sbl_lib_cust_LIBNAME
448 export sbl_lib_cust_LIBPATH
449 sbl_lib_cust_BOARD_DEPENDENCY = yes
450 sbl_lib_cust_SOC_DEPENDENCY = yes
451 sbl_lib_cust_CORE_DEPENDENCY = no
452 export sbl_lib_cust_COMP_LIST
453 export sbl_lib_cust_BOARD_DEPENDENCY
454 export sbl_lib_cust_CORE_DEPENDENCY
455 sbl_lib_cust_PKG_LIST = sbl_lib_cust
456 sbl_lib_cust_INCLUDE = $(sbl_lib_cust_PATH)
457 sbl_lib_cust_SOCLIST = $(CUST_SBL_TEST_SOCS)
458 sbl_lib_cust_BOARDLIST = $(CUST_SBL_TEST_BOARDS)
459 export sbl_lib_cust_SOCLIST
460 export sbl_lib_cust_BOARDLIST
461 sbl_lib_cust_$(SOC)_CORELIST = mcu1_0
462 export sbl_lib_cust_$(SOC)_CORELIST
464 # SBL custom image
465 sbl_cust_img_COMP_LIST = sbl_cust_img
466 sbl_cust_img_RELPATH = ti/boot/sbl/board/k3
467 sbl_cust_img_CUSTOM_BINPATH = $(PDK_SBL_COMP_PATH)/binary/$(BOARD)/cust/bin
468 sbl_cust_img_PATH = $(PDK_SBL_COMP_PATH)/board/k3
469 sbl_cust_img_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_img.mk BOOTMODE=cust CUST_SBL_FLAGS=$(CUST_SBL_TEST_FLAGS)
470 export sbl_cust_img_MAKEFILE
471 sbl_cust_img_BOARD_DEPENDENCY = yes
472 sbl_cust_img_SOC_DEPENDENCY = yes
473 sbl_cust_img_CORE_DEPENDENCY = no
474 export sbl_cust_img_COMP_LIST
475 export sbl_cust_img_BOARD_DEPENDENCY
476 export sbl_cust_img_SOC_DEPENDENCY
477 export sbl_cust_img_CORE_DEPENDENCY
478 sbl_cust_img_PKG_LIST = sbl
479 sbl_cust_img_INCLUDE = $(sbl_cust_img_PATH)
480 sbl_cust_img_SOCLIST = $(CUST_SBL_TEST_SOCS)
481 sbl_cust_img_BOARDLIST = $(CUST_SBL_TEST_BOARDS)
482 export sbl_cust_img_SOCLIST
483 export sbl_cust_img_BOARDLIST
484 sbl_cust_img_$(SOC)_CORELIST = mcu1_0
485 export sbl_cust_img_$(SOC)_CORELIST
486 sbl_EXAMPLE_LIST += sbl_cust_img
487 sbl_cust_img_SBL_IMAGEGEN = yes
488 export sbl_cust_img_SBL_IMAGEGEN
490 # R5 boot performance Test - works only with custom SBL
491 sbl_boot_perf_test_COMP_LIST = sbl_boot_perf_test
492 sbl_boot_perf_test_RELPATH = ti/boot/sbl/example/k3MulticoreApp
493 sbl_boot_perf_test_BINPATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp/binary
494 sbl_boot_perf_test_PATH = $(PDK_SBL_COMP_PATH)/example/k3MulticoreApp
495 sbl_boot_perf_test_MAKEFILE = -f$(PDK_SBL_COMP_PATH)/build/sbl_mcu0_boot_perf_test.mk BOOTMODE=cust CUST_SBL_FLAGS=$(CUST_SBL_TEST_FLAGS)
496 export sbl_boot_perf_test_MAKEFILE
497 sbl_boot_perf_test_BOARD_DEPENDENCY = no
498 sbl_boot_perf_test_SOC_DEPENDENCY = no
499 sbl_boot_perf_test_CORE_DEPENDENCY = no
500 export sbl_boot_perf_test_COMP_LIST
501 export sbl_boot_perf_test_BOARD_DEPENDENCY
502 export sbl_boot_perf_test_SOC_DEPENDENCY
503 export sbl_boot_perf_test_CORE_DEPENDENCY
504 sbl_boot_perf_test_PKG_LIST = sbl_boot_perf_test
505 sbl_boot_perf_test_INCLUDE = $(sbl_boot_perf_test_PATH)
506 sbl_boot_perf_test_SOCLIST = $(CUST_SBL_TEST_SOCS)
507 sbl_boot_perf_test_BOARDLIST = $(CUST_SBL_TEST_BOARDS)
508 export sbl_boot_perf_test_SOCLIST
509 export sbl_boot_perf_test_BOARDLIST
510 sbl_boot_perf_test_$(SOC)_CORELIST = mcu1_0
511 export sbl_boot_perf_test_$(SOC)_CORELIST
512 sbl_EXAMPLE_LIST += sbl_boot_perf_test
513 sbl_boot_perf_test_SBL_APPIMAGEGEN = yes
514 export sbl_boot_perf_test_SBL_APPIMAGEGEN
516 export sbl_LIB_LIST
517 export sbl_EXAMPLE_LIST
518 export SBL_CFLAGS
520 sbl_component_make_include := 1
521 endif