[Patch V3] UefiPayloadPkg: Use DynamicEx instead of Dynamic to pass PCD across binary


Zhiguang Liu
 

V1:
When passing PCD database from Edk2 boot loader to Universal Payload, the l=
ocal
token number in boot loader PCD database can be different with that in Payl=
oad
PCD database.
Dynamic PCD directly use local token number, while DynamicEx will search to=
ken number
by Guid and ExTokenNumber, which are unique pair and can make sure finding =
the correct
token number in boot loader's PCD database
V2:
Remove PCD PcdFlashNvStorageFtwWorkingBase and PcdFlashNvStorageFtwSpareBas=
e, because they
are not consumed by any modules.
Explicitly define some PCDs as DynamicEx, or their default type will be Dyn=
amic

V3:
Not remove some PCDs for they will be consumed soon

Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Guo Dong <guo.dong@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>

Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
---
UefiPayloadPkg/UefiPayloadPkg.dsc | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/UefiPayloadPkg/UefiPayloadPkg.dsc b/UefiPayloadPkg/UefiPayload=
Pkg.dsc
index 37ad5a0ae7..4b0ec3a059 100644
--- a/UefiPayloadPkg/UefiPayloadPkg.dsc
+++ b/UefiPayloadPkg/UefiPayloadPkg.dsc
@@ -336,11 +336,11 @@
=0D
##########################################################################=
######=0D
#=0D
-# Pcd Dynamic Section - list of all EDK II PCD Entries defined by this Pla=
tform=0D
+# Pcd DynamicEx Section - list of all EDK II PCD Entries defined by this P=
latform=0D
#=0D
##########################################################################=
######=0D
=0D
-[PcdsDynamicDefault]=0D
+[PcdsDynamicExDefault]=0D
gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvStoreReserved|0=0D
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64|0=0D
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase|0=0D
@@ -363,6 +363,9 @@
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|100=0D
gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0=0D
gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseSize|0=0D
+ gEfiMdeModulePkgTokenSpaceGuid.PcdGhcbBase|0=0D
+ gEfiMdeModulePkgTokenSpaceGuid.PcdTestKeyUsed|FALSE=0D
+ gUefiCpuPkgTokenSpaceGuid.PcdSevEsIsEnabled|0=0D
=0D
##########################################################################=
######=0D
#=0D
--=20
2.30.0.windows.2

Join devel@edk2.groups.io to automatically receive all group messages.