]> git.baikalelectronics.ru Git - arm-tf.git/commitdiff
juno/sgm: Maximize space allocated to SCP_BL2
authorChris Kay <chris.kay@arm.com>
Thu, 12 Mar 2020 13:50:26 +0000 (13:50 +0000)
committerChris Kay <chris.kay@arm.com>
Thu, 12 Mar 2020 15:12:23 +0000 (15:12 +0000)
To accommodate the increasing size of the SCP_BL2 binary, the base
address of the memory region allocated to SCP_BL2 has been moved
downwards from its current (mostly) arbitrary address to the beginning
of the non-shared trusted SRAM.

Change-Id: I086a3765bf3ea88f45525223d765dc0dbad6b434
Signed-off-by: Chris Kay <chris.kay@arm.com>
docs/design/firmware-design.rst
plat/arm/board/juno/include/platform_def.h
plat/arm/css/sgm/include/sgm_base_platform_def.h

index 8297dc78523adbd9458706208ea291e82653a4c1..8e9dc38e4dce341c85ea8ee76a9f2730ddc4303e 100644 (file)
@@ -1859,7 +1859,7 @@ BL image during boot.
                |   BL2    |  <<<<<<<<<<<<<  |                |
                |----------|  <<<<<<<<<<<<<  |----------------|
                | SCP_BL2  |  <<<<<<<<<<<<<  | BL31 PROGBITS  |
-               |----------|  <<<<<<<<<<<<<  |----------------|
+               |          |  <<<<<<<<<<<<<  |----------------|
                |          |  <<<<<<<<<<<<<  |     BL32       |
                |          |                 +----------------+
                |          |
@@ -1896,7 +1896,7 @@ BL image during boot.
                |   BL2    |  <<<<<<<<<<<<<  |                |
                |----------|  <<<<<<<<<<<<<  |----------------|
                | SCP_BL2  |  <<<<<<<<<<<<<  | BL31 PROGBITS  |
-               |----------|                 +----------------+
+               |          |                 +----------------+
     0x04001000 +----------+
                |   MHU    |
     0x04000000 +----------+
index cfac801829d4f1ba93aecb4daf9448a5fb6960f4..b44639528a58c23650a3500f98f820a4f684728e 100644 (file)
 #endif
 
 /*
- * PLAT_CSS_MAX_SCP_BL2_SIZE is calculated using the current
- * SCP_BL2 size plus a little space for growth.
+ * SCP_BL2 uses up whatever remaining space is available as it is loaded before
+ * anything else in this memory region and is handed over to the SCP before
+ * BL31 is loaded over the top.
  */
-#define PLAT_CSS_MAX_SCP_BL2_SIZE      UL(0x14000)
-
-/*
- * PLAT_CSS_MAX_SCP_BL2U_SIZE is calculated using the current
- * SCP_BL2U size plus a little space for growth.
- */
-#define PLAT_CSS_MAX_SCP_BL2U_SIZE     UL(0x14000)
+#define PLAT_CSS_MAX_SCP_BL2_SIZE      (SCP_BL2_LIMIT - ARM_TB_FW_CONFIG_LIMIT)
+#define PLAT_CSS_MAX_SCP_BL2U_SIZE     PLAT_CSS_MAX_SCP_BL2_SIZE
 
 #define PLAT_ARM_G1S_IRQ_PROPS(grp) \
        CSS_G1S_IRQ_PROPS(grp), \
index 90511ac6a7348581ee3a9116a3300c69b28b1af4..0ac0c2b3c42b28a100b710e08f8123de2a044847 100644 (file)
 #endif
 
 /*
- * PLAT_CSS_MAX_SCP_BL2_SIZE is calculated using the current
- * SCP_BL2 size plus a little space for growth.
+ * SCP_BL2 uses up whatever remaining space is available as it is loaded before
+ * anything else in this memory region and is handed over to the SCP before
+ * BL31 is loaded over the top.
  */
-#define PLAT_CSS_MAX_SCP_BL2_SIZE      0x15000
-
-/*
- * PLAT_CSS_MAX_SCP_BL2U_SIZE is calculated using the current
- * SCP_BL2U size plus a little space for growth.
- */
-#define PLAT_CSS_MAX_SCP_BL2U_SIZE     0x15000
+#define PLAT_CSS_MAX_SCP_BL2_SIZE      (SCP_BL2_LIMIT - ARM_TB_FW_CONFIG_LIMIT)
+#define PLAT_CSS_MAX_SCP_BL2U_SIZE     PLAT_CSS_MAX_SCP_BL2_SIZE
 
 /*
  * Most platform porting definitions provided by included headers