[edk2-devel] [PATCH V2 05/10] OvmfPkg: Update EFI_HOB_PLATFORM_INFO with more platform settings

Min Xu min.m.xu at intel.com
Tue Jan 25 06:33:13 UTC 2022


RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3429

This patch-sets is to bring up Legacy guest and Tdx guest without
PEI phase. So platform initialization has to be done in SEC phase.
It is similar with the work of OvmfPkg/PlatformPei. In
OvmfPkg/PlatformPei some PCDs are set during platform initialization,
such as PcdPciMmio64Base. But in PEI-less boot, PCDs cannot be set.
So these values are saved in EFI_HOB_PLATFORM_INFO. Then in the early
stage of DXE phase this hob will be parsed and PCDs are set accordingly.

Cc: Michael D Kinney <michael.d.kinney at intel.com>
Cc: Brijesh Singh <brijesh.singh at amd.com>
Cc: Erdem Aktas <erdemaktas at google.com>
Cc: James Bottomley <jejb at linux.ibm.com>
Cc: Jiewen Yao <jiewen.yao at intel.com>
Cc: Tom Lendacky <thomas.lendacky at amd.com>
Cc: Gerd Hoffmann <kraxel at redhat.com>
Signed-off-by: Min Xu <min.m.xu at intel.com>
---
 OvmfPkg/Include/IndustryStandard/IntelTdx.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/OvmfPkg/Include/IndustryStandard/IntelTdx.h b/OvmfPkg/Include/IndustryStandard/IntelTdx.h
index 44155adefd58..a37ad28f7bf4 100644
--- a/OvmfPkg/Include/IndustryStandard/IntelTdx.h
+++ b/OvmfPkg/Include/IndustryStandard/IntelTdx.h
@@ -65,6 +65,23 @@ typedef struct {
 typedef struct {
   EFI_HOB_GUID_TYPE    GuidHeader;
   UINT16               HostBridgePciDevId;
+  BOOLEAN              PcdSetNxForStack;
+  UINT8                SystemStates[6];
+
+  UINT64               PcdConfidentialComputingGuestAttr;
+  BOOLEAN              PcdIa32EferChangeAllowed;
+  UINT64               PcdTdxSharedBitMask;
+
+  UINT64               PcdPciMmio64Base;
+  UINT64               PcdPciMmio64Size;
+  UINT32               PcdPciMmio32Base;
+  UINT32               PcdPciMmio32Size;
+  UINT64               PcdPciIoBase;
+  UINT64               PcdPciIoSize;
+
+  UINT64               PcdEmuVariableNvStoreReserved;
+  UINT32               PcdCpuBootLogicalProcessorNumber;
+  UINT32               PcdCpuMaxLogicalProcessorNumber;
 } EFI_HOB_PLATFORM_INFO;
 
 #pragma pack()
-- 
2.29.2.windows.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#86042): https://edk2.groups.io/g/devel/message/86042
Mute This Topic: https://groups.io/mt/88666802/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-





More information about the edk2-devel-archive mailing list