blob: f66612b1f4e6b018f0a75709861ac199f8147ad6 [file] [log] [blame]
Yann Gautiera3f46382023-06-14 10:40:59 +02001#
2# Copyright (c) 2023, STMicroelectronics - All Rights Reserved
3#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6
7include plat/st/common/common.mk
8
9CRASH_REPORTING := 1
10ENABLE_PIE := 1
11PROGRAMMABLE_RESET_ADDRESS := 1
12
13# Default Device tree
14DTB_FILE_NAME ?= stm32mp257f-ev1.dtb
15
16STM32MP25 := 1
17
18# STM32 image header version v2.2
19STM32_HEADER_VERSION_MAJOR := 2
20STM32_HEADER_VERSION_MINOR := 2
21
22# Number of TF-A copies in the device
23STM32_TF_A_COPIES := 2
24
25# PLAT_PARTITION_MAX_ENTRIES must take care of STM32_TF-A_COPIES and other partitions
26# such as metadata (2) and fsbl-m (2) to find all the FIP partitions (default is 2).
27PLAT_PARTITION_MAX_ENTRIES := $(shell echo $$(($(STM32_TF_A_COPIES) + 6)))
28
29# STM32MP2x is based on Cortex-A35, which is Armv8.0, and does not support BTI
30# Disable mbranch-protection to avoid adding useless code
31TF_CFLAGS += -mbranch-protection=none
32
33# Include paths and source files
34PLAT_INCLUDES += -Iplat/st/stm32mp2/include/
35
36PLAT_BL_COMMON_SOURCES += lib/cpus/${ARCH}/cortex_a35.S
37
38PLAT_BL_COMMON_SOURCES += plat/st/stm32mp2/${ARCH}/stm32mp2_helper.S
39
40BL2_SOURCES += plat/st/stm32mp2/plat_bl2_mem_params_desc.c
41BL2_SOURCES += plat/st/stm32mp2/bl2_plat_setup.c
42
43include plat/st/common/common_rules.mk