diff --git a/docs/components/realm-management-extension.rst b/docs/components/realm-management-extension.rst index 6fc0c2e25..2ea8012cc 100644 --- a/docs/components/realm-management-extension.rst +++ b/docs/components/realm-management-extension.rst @@ -196,7 +196,7 @@ and run the default tests including Realm world tests. -C bp.refcounter.use_real_time=0 \ -C bp.ve_sysregs.exit_on_shutdown=1 \ -C cache_state_modelled=1 \ - -C bp.dram_size=2 \ + -C bp.dram_size=4 \ -C bp.secure_memory=1 \ -C pci.pci_smmuv3.mmu.SMMU_ROOT_IDR0=3 \ -C pci.pci_smmuv3.mmu.SMMU_ROOT_IIDR=0x43B \ diff --git a/fdts/fvp-base-psci-common.dtsi b/fdts/fvp-base-psci-common.dtsi index 6018f0cc2..7838fde4d 100644 --- a/fdts/fvp-base-psci-common.dtsi +++ b/fdts/fvp-base-psci-common.dtsi @@ -28,7 +28,7 @@ #size-cells = <2>; #if (ENABLE_RME == 1) - chosen { bootargs = "mem=1G console=ttyAMA0 earlycon=pl011,0x1c090000 root=/dev/vda ip=on";}; + chosen { bootargs = "console=ttyAMA0 earlycon=pl011,0x1c090000 root=/dev/vda ip=on";}; #else chosen {}; #endif diff --git a/include/plat/arm/common/arm_pas_def.h b/include/plat/arm/common/arm_pas_def.h index c199302e8..fba8d2c70 100644 --- a/include/plat/arm/common/arm_pas_def.h +++ b/include/plat/arm/common/arm_pas_def.h @@ -21,24 +21,30 @@ * ============================================================================ * 0GB | 1GB |L0 GPT|ANY |TBROM (EL3 code) |Fixed mapping * | | | |TSRAM (EL3 data) | - * | | | |IO (incl.UARTs & GIC) | + * 00000000 | | | |IO (incl.UARTs & GIC) | * ---------------------------------------------------------------------------- * 1GB | 1GB |L0 GPT|ANY |IO |Fixed mapping + * 40000000 | | | | | * ---------------------------------------------------------------------------- - * 2GB | 1GB |L1 GPT|NS |DRAM (NS Kernel) |Use T.Descrip + * 2GB |2GB-64MB |L1 GPT|NS |DRAM (NS Kernel) |Use T.Descrip + * 80000000 | | | | | * ---------------------------------------------------------------------------- - * 3GB |1GB-64MB |L1 GPT|NS |DRAM (NS Kernel) |Use T.Descrip - * ---------------------------------------------------------------------------- - * 4GB-64MB |64MB-32MB | | | | - * | -4MB |L1 GPT|SECURE|DRAM TZC |Use T.Descrip + * 4GB-64MB |64MB-32MB-4MB|L1 GPT|SECURE|DRAM TZC |Use T.Descrip + * FC000000 | | | | | * ---------------------------------------------------------------------------- * 4GB-32MB | | | | | * -3MB-1MB |32MB |L1 GPT|REALM |RMM |Use T.Descrip + * FDC00000 | | | | | * ---------------------------------------------------------------------------- * 4GB-3MB | | | | | * -1MB |3MB |L1 GPT|ROOT |EL3 DRAM data |Use T.Descrip + * FFC00000 | | | | | * ---------------------------------------------------------------------------- * 4GB-1MB |1MB |L1 GPT|ROOT |DRAM (L1 GPTs, SCP TZC) |Fixed mapping + * FFF00000 | | | | | + * ---------------------------------------------------------------------------- + * 34GB |2GB |L1 GPT|NS |DRAM (NS Kernel) |Use T.Descrip + * 880000000| | | | | * ============================================================================ * * - 4KB of L0 GPT reside in TSRAM, on top of the CONFIG section. @@ -55,7 +61,7 @@ /* Device memory 0 to 2GB */ #define ARM_PAS_1_BASE (U(0)) -#define ARM_PAS_1_SIZE ((ULL(1)<<31)) /* 2GB */ +#define ARM_PAS_1_SIZE ((ULL(1) << 31)) /* 2GB */ /* NS memory 2GB to (end - 64MB) */ #define ARM_PAS_2_BASE (ARM_PAS_1_BASE + ARM_PAS_1_SIZE) @@ -69,9 +75,14 @@ #define ARM_PAS_3_BASE (ARM_AP_TZC_DRAM1_BASE) #define ARM_PAS_3_SIZE (ARM_AP_TZC_DRAM1_SIZE) +/* NS memory 2GB */ +#define ARM_PAS_4_BASE ARM_DRAM2_BASE +#define ARM_PAS_4_SIZE ((ULL(1) << 31)) /* 2GB */ + #define ARM_PAS_GPI_ANY MAP_GPT_REGION(ARM_PAS_1_BASE, \ ARM_PAS_1_SIZE, \ GPT_GPI_ANY) + #define ARM_PAS_KERNEL GPT_MAP_REGION_GRANULE(ARM_PAS_2_BASE, \ ARM_PAS_2_SIZE, \ GPT_GPI_NS) @@ -80,6 +91,9 @@ ARM_PAS_3_SIZE, \ GPT_GPI_SECURE) +#define ARM_PAS_KERNEL_1 GPT_MAP_REGION_GRANULE(ARM_PAS_4_BASE, \ + ARM_PAS_4_SIZE, \ + GPT_GPI_NS) /* * REALM and Shared area share the same PAS, so consider them a single * PAS region to configure in GPT. diff --git a/plat/arm/common/arm_bl2_setup.c b/plat/arm/common/arm_bl2_setup.c index 08c014d8e..02e419a43 100644 --- a/plat/arm/common/arm_bl2_setup.c +++ b/plat/arm/common/arm_bl2_setup.c @@ -143,11 +143,12 @@ static void arm_bl2_plat_gpt_setup(void) ARM_PAS_SECURE, ARM_PAS_REALM, ARM_PAS_EL3_DRAM, - ARM_PAS_GPTS + ARM_PAS_GPTS, + ARM_PAS_KERNEL_1 }; /* Initialize entire protected space to GPT_GPI_ANY. */ - if (gpt_init_l0_tables(GPCCR_PPS_4GB, ARM_L0_GPT_ADDR_BASE, + if (gpt_init_l0_tables(GPCCR_PPS_64GB, ARM_L0_GPT_ADDR_BASE, ARM_L0_GPT_SIZE) < 0) { ERROR("gpt_init_l0_tables() failed!\n"); panic();