BaseTools: Fix an issue in HiiPcd generation
authorBobCF <bob.c.feng@intel.com>
Tue, 2 Jan 2018 00:58:33 +0000 (08:58 +0800)
committerLiming Gao <liming.gao@intel.com>
Mon, 8 Jan 2018 03:29:13 +0000 (11:29 +0800)
DynamicHiiPcd may be used by PEIM or DXE driver.
All used DynamicHiiPcd value should be collected and placed into
the default setting PCD PcdNvStoreDefaultValueBuffer.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Bob Feng <bob.c.feng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
BaseTools/Source/Python/AutoGen/AutoGen.py

index 8be5bfca8342a43beec2b31d4e5dd26e94a830c2..758355c366969d308db42a5762f0d7843d712b29 100644 (file)
@@ -1405,9 +1405,8 @@ class PlatformAutoGen(AutoGen):
                 if len(Sku.VariableName) > 0:\r
                     VariableGuidStructure = Sku.VariableGuidValue\r
                     VariableGuid = GuidStructureStringToGuidString(VariableGuidStructure)\r
-                    if Pcd.Phase == "DXE":\r
-                        for StorageName in Sku.DefaultStoreDict:\r
-                            VariableInfo.append_variable(var_info(Index,pcdname,StorageName,SkuName, StringToArray(Sku.VariableName),VariableGuid, Sku.VariableAttribute , Sku.HiiDefaultValue,Sku.DefaultStoreDict[StorageName],Pcd.DatumType))\r
+                    for StorageName in Sku.DefaultStoreDict:\r
+                        VariableInfo.append_variable(var_info(Index,pcdname,StorageName,SkuName, StringToArray(Sku.VariableName),VariableGuid, Sku.VariableAttribute , Sku.HiiDefaultValue,Sku.DefaultStoreDict[StorageName],Pcd.DatumType))\r
             Index += 1\r
         return VariableInfo\r
 \r