mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-30 07:39:24 +00:00
stm32mp1: set XN attribute for some areas in BL2
DTB and BL32 area should not be set as executable in MMU during BL2 execution, hence set those areas as MT_RO_DATA. Change-Id: I87c47a1e7fda761e541ec98a5b294588384d31db Signed-off-by: Yann Gautier <yann.gautier@st.com>
This commit is contained in:
parent
84686ba347
commit
9c52e69fb4
1 changed files with 2 additions and 2 deletions
|
@ -190,12 +190,12 @@ void bl2_el3_plat_arch_setup(void)
|
||||||
/* Prevent corruption of preloaded BL32 */
|
/* Prevent corruption of preloaded BL32 */
|
||||||
mmap_add_region(BL32_BASE, BL32_BASE,
|
mmap_add_region(BL32_BASE, BL32_BASE,
|
||||||
BL32_LIMIT - BL32_BASE,
|
BL32_LIMIT - BL32_BASE,
|
||||||
MT_MEMORY | MT_RO | MT_SECURE);
|
MT_RO_DATA | MT_SECURE);
|
||||||
#endif
|
#endif
|
||||||
/* Prevent corruption of preloaded Device Tree */
|
/* Prevent corruption of preloaded Device Tree */
|
||||||
mmap_add_region(DTB_BASE, DTB_BASE,
|
mmap_add_region(DTB_BASE, DTB_BASE,
|
||||||
DTB_LIMIT - DTB_BASE,
|
DTB_LIMIT - DTB_BASE,
|
||||||
MT_MEMORY | MT_RO | MT_SECURE);
|
MT_RO_DATA | MT_SECURE);
|
||||||
|
|
||||||
configure_mmu();
|
configure_mmu();
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue