]> git.baikalelectronics.ru Git - arm-tf.git/commitdiff
plat: tc0: Configure TZC with secure world regions
authorUsama Arif <usama.arif@arm.com>
Wed, 26 Aug 2020 13:04:31 +0000 (14:04 +0100)
committerManish Pandey <manish.pandey2@arm.com>
Tue, 20 Oct 2020 20:07:17 +0000 (20:07 +0000)
This includes configuration for SPMC and trusted OS.

Change-Id: Ie24df200f446b3f5b23f5f764b115c7191e6ada3
Signed-off-by: Usama Arif <usama.arif@arm.com>
Signed-off-by: Arunachalam Ganapathy <arunachalam.ganapathy@arm.com>
plat/arm/board/tc0/include/platform_def.h
plat/arm/board/tc0/tc0_security.c

index dbec706faca7219808bd851dccc779c6578ea020..72a035f0ab50f1a491b3529852fa04f99e4681da 100644 (file)
 #define PLAT_ARM_TZC_NS_DEV_ACCESS     \
                (TZC_REGION_ACCESS_RDWR(TZC_NSAID_DEFAULT))
 
+/*
+ * The first region below, TC0_TZC_DRAM1_BASE (0xfd000000) to
+ * ARM_SCP_TZC_DRAM1_END (0xffffffff) will mark the last 48 MB of DRAM as
+ * secure. The second region gives non secure access to rest of DRAM.
+ */
+#define TC0_TZC_REGIONS_DEF                                            \
+       {TC0_TZC_DRAM1_BASE, ARM_SCP_TZC_DRAM1_END,                     \
+               TZC_REGION_S_RDWR, PLAT_ARM_TZC_NS_DEV_ACCESS},         \
+       {TC0_NS_DRAM1_BASE, TC0_NS_DRAM1_END, ARM_TZC_NS_DRAM_S_ACCESS, \
+               PLAT_ARM_TZC_NS_DEV_ACCESS}
+
 /* virtual address used by dynamic mem_protect for chunk_base */
 #define PLAT_ARM_MEM_PROTEC_VA_FRAME   UL(0xc0000000)
 
index 5f1cb1159b047157bf0e54e04b87a214e52163a1..f543762036c99e94e916a246797cabf323a215f6 100644 (file)
@@ -8,7 +8,7 @@
 #include <platform_def.h>
 
 static const arm_tzc_regions_info_t tzc_regions[] = {
-       ARM_TZC_REGIONS_DEF,
+       TC0_TZC_REGIONS_DEF,
        {}
 };