This patchset adds support for creating a MM Standalone image suitable for running on a Base FVP in the AArch64 execution state.
The core support for instantiating MM Standalone mode is being developed in the following edk2-staging branch:
https://github.com/tianocore/edk2-staging/tree/AArch64StandaloneMm
This branch and the patchset should be combined to build a MM Standalone image. The instructions for this will be updated in edk2-staging later.
The changes in this series are aimed at:
1. partitioning DRAM to set aside memory for the MM Standalone image 2. including the necessary modules to instantiate the Standalone MM on the Base FVP
This patchset should be staged in a separate branch until it is clearer how the MM Standalone image should be supported on common ARM platforms.
Achin Gupta (4): Platforms/ARM/VExpress: Size DRAM to accommodate Standalone MM image Platforms/ARM/VExpress: Define extents of MM communication buffer Platforms/ARM/VExpress: Include MM communication protocol driver Platforms/ARM/VExpress: Include UEFI Info application in FVP build
Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 10 +++++++++- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf | 4 ++++ 2 files changed, 13 insertions(+), 1 deletion(-)
-- 1.9.1 IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
From: Achin Gupta achin.gupta@arm.com
This patch reduces the size of the DRAM available to UEFI so that the freed memory can be used to load the Standalone MM image in the secure world.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Achin Gupta achin.gupta@arm.com --- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc index cf4b803..938c7a0 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc @@ -109,7 +109,7 @@
# System Memory (2GB - 16MB of Trusted DRAM at the top of the 32bit address space) gArmTokenSpaceGuid.PcdSystemMemoryBase|0x80000000 - gArmTokenSpaceGuid.PcdSystemMemorySize|0x7F000000 + gArmTokenSpaceGuid.PcdSystemMemorySize|0x74000000
# Size of the region used by UEFI in permanent memory (Reserved 64MB) gArmPlatformTokenSpaceGuid.PcdSystemMemoryUefiRegionSize|0x04000000 -- 1.9.1
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
From: Achin Gupta achin.gupta@arm.com
The secure world firmware (e.g. ARM Trusted Firmware) allocates the communication buffer used in the MM Communicate SMC. EDK2 is expected to map this buffer in its own address map. In the absence of a mechanism where ARM TF can pass the extents of this buffer at runtime to EDK2, this patch hard codes this information in the UEFI binary for the ARM FVP.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Achin Gupta achin.gupta@arm.com --- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc index 938c7a0..8d6a69d 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc @@ -122,6 +122,9 @@ ## Trustzone enable (to make the transition from EL3 to NS EL2 in ArmPlatformPkg/Sec) gArmTokenSpaceGuid.PcdTrustzoneSupport|TRUE
+ gArmTokenSpaceGuid.PcdMmBufferBase|0xFBE00000 + gArmTokenSpaceGuid.PcdMmBufferSize|0x200000 + # # ARM PrimeCell # -- 1.9.1
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
From: Achin Gupta achin.gupta@arm.com
This patch includes the DXE runtime driver that exports the EFI_MM_COMMUNICATION_PROTOCOL for the FVP platform. This driver is responsible for handling communication with the MM environment in the secure world. An implementation of the ARM SVC lib is also include in the FVP build.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Achin Gupta achin.gupta@arm.com --- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 4 ++++ Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf | 3 +++ 2 files changed, 7 insertions(+)
diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc index 8d6a69d..b6db588 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc @@ -40,6 +40,7 @@
[LibraryClasses.common] ArmLib|ArmPkg/Library/ArmLib/ArmBaseLib.inf + ArmSvcLib|ArmPkg/Library/ArmSvcLib/ArmSvcLib.inf ArmCpuLib|ArmPkg/Drivers/ArmCpuLib/ArmCortexAEMv8Lib/ArmCortexAEMv8Lib.inf ArmPlatformLib|ArmPlatformPkg/ArmVExpressPkg/Library/ArmVExpressLibRTSM/ArmVExpressLib.inf ArmMmuLib|ArmPkg/Library/ArmMmuLib/ArmMmuBaseLib.inf @@ -287,6 +288,9 @@
MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
+ # Standalone MM Support + ArmPkg/Drivers/MmCommunicationDxe/MmCommunication.inf + # # Semi-hosting filesystem # diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf index 2ace4d8..0e9f8d1 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf @@ -142,6 +142,9 @@ FvNameGuid = 87940482-fc81-41c3-87e6-399cf85ac8a0 # INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
+ # Standalone MM Support + INF ArmPkg/Drivers/MmCommunicationDxe/MmCommunication.inf + # # Platform Driver # -- 1.9.1
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
From: Achin Gupta achin.gupta@arm.com
This patch includes the UEFI Info application in the FVP build to demonstrate communication with the MM environment in the secure world through the DXE runtime driver that exports the EFI_MM_COMMUNICATE_PROTOCOL.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Achin Gupta achin.gupta@arm.com --- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 1 + Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf | 1 + 2 files changed, 2 insertions(+)
diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc index b6db588..f07e279 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc @@ -290,6 +290,7 @@
# Standalone MM Support ArmPkg/Drivers/MmCommunicationDxe/MmCommunication.inf + MdeModulePkg/Application/UefiInfoApp/UefiInfo.inf
# # Semi-hosting filesystem diff --git a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf index 0e9f8d1..93accf6 100644 --- a/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf +++ b/Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf @@ -144,6 +144,7 @@ FvNameGuid = 87940482-fc81-41c3-87e6-399cf85ac8a0
# Standalone MM Support INF ArmPkg/Drivers/MmCommunicationDxe/MmCommunication.inf + INF MdeModulePkg/Application/UefiInfoApp/UefiInfo.inf
# # Platform Driver -- 1.9.1
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
Hi Achin,
(Please cc my Linaro email instead of the ARM one.)
On Wed, Dec 07, 2016 at 10:22:58AM +0000, achin.gupta@arm.com wrote:
This patchset adds support for creating a MM Standalone image suitable for running on a Base FVP in the AArch64 execution state.
The core support for instantiating MM Standalone mode is being developed in the following edk2-staging branch:
https://github.com/tianocore/edk2-staging/tree/AArch64StandaloneMm
This branch and the patchset should be combined to build a MM Standalone image. The instructions for this will be updated in edk2-staging later.
The changes in this series are aimed at:
- partitioning DRAM to set aside memory for the MM Standalone image
- including the necessary modules to instantiate the Standalone MM on the Base FVP
This patchset should be staged in a separate branch until it is clearer how the MM Standalone image should be supported on common ARM platforms.
I'm fine with that - what would you like the branch called?
Achin Gupta (4): Platforms/ARM/VExpress: Size DRAM to accommodate Standalone MM image Platforms/ARM/VExpress: Define extents of MM communication buffer Platforms/ARM/VExpress: Include MM communication protocol driver Platforms/ARM/VExpress: Include UEFI Info application in FVP build
I have looked at your patches, and they seem to make sense. One generic request though - could you put all of these additions inside !if $(MM_ENABLE) == TRUE statements?
Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.dsc | 10 +++++++++- Platforms/ARM/VExpress/ArmVExpress-FVP-AArch64.fdf | 4 ++++ 2 files changed, 13 insertions(+), 1 deletion(-)
-- 1.9.1
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
Can you look into getting access to the no-disclaimer route, to ensure misleading legal statements are not sent to public mailing lists?
Regards,
Leif
Linaro-uefi mailing list Linaro-uefi@lists.linaro.org https://lists.linaro.org/mailman/listinfo/linaro-uefi