From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web11.1232.1689086242061438071 for ; Tue, 11 Jul 2023 07:37:22 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: nishant.sharma@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 022452F4; Tue, 11 Jul 2023 07:38:04 -0700 (PDT) Received: from usa.arm.com (iss-desktop02.cambridge.arm.com [10.1.196.79]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id D85E13F740; Tue, 11 Jul 2023 07:37:20 -0700 (PDT) From: "Nishant Sharma" To: devel@edk2.groups.io Cc: Ard Biesheuvel , Sami Mujawar , Thomas Abraham , Sayanta Pattanayak , Achin Gupta Subject: [edk2-platforms][PATCH V1 07/20] StandaloneMmPkg: define new data structure to stage FF-A boot information Date: Tue, 11 Jul 2023 15:36:45 +0100 Message-Id: <20230711143658.781597-8-nishant.sharma@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230711143658.781597-1-nishant.sharma@arm.com> References: <20230711143658.781597-1-nishant.sharma@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Achin Gupta With FF-A v1.1, the SPMC sends a reduced amount of boot information as compared to the original SPM implementation. For example, the stack layou= t, MP information etc. This information could be accommodated in the old dat= a structure but this is too complicated. This patch defines a new structure to clearly separate FF-A v1.1 and other functionality. Signed-off-by: Achin Gupta Signed-off-by: Nishant Sharma --- StandaloneMmPkg/Include/Library/Arm/StandaloneMmCoreEntryPoint.h | 21 ++= ++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/StandaloneMmPkg/Include/Library/Arm/StandaloneMmCoreEntryPoi= nt.h b/StandaloneMmPkg/Include/Library/Arm/StandaloneMmCoreEntryPoint.h index 41bf0f132b4f..c965192c702e 100644 --- a/StandaloneMmPkg/Include/Library/Arm/StandaloneMmCoreEntryPoint.h +++ b/StandaloneMmPkg/Include/Library/Arm/StandaloneMmCoreEntryPoint.h @@ -47,6 +47,27 @@ typedef struct { EFI_SECURE_PARTITION_CPU_INFO *CpuInfo; } EFI_SECURE_PARTITION_BOOT_INFO; =20 + +/** + This structure is used to stage boot information required to initializ= e the + standalone MM environment when FF-A is used as the interface between t= his + secure partition and the SPMC. This structure supersedes + EFI_SECURE_PARTITION_BOOT_INFO and reduces the amount of information t= hat must + be passed by the SPMC for SP initialization. +**/ +typedef struct { + UINT64 SpMemBase; + UINT64 SpMemSize; + UINT64 SpNsCommBufBase; + UINT64 SpNsCommBufSize; + UINT64 SpSharedBufBase; + UINT64 SpSharedBufSize; + UINT64 SpHeapBase; + UINT64 SpHeapSize; + /* UP migrate-able FF-A SP requires awareness of only 1 cpu */ + EFI_SECURE_PARTITION_CPU_INFO CpuInfo; +} EFI_STMM_BOOT_INFO; + typedef EFI_STATUS (*PI_MM_ARM_TF_CPU_DRIVER_ENTRYPOINT) ( --=20 2.34.1