summaryrefslogtreecommitdiffstats
path: root/BaseTools/Source/Python/AutoGen/GenPcdDb.py
diff options
context:
space:
mode:
authorJaben Carsey <jaben.carsey@intel.com>2018-05-18 08:06:52 +0800
committerYonghong Zhu <yonghong.zhu@intel.com>2018-06-13 09:02:56 +0800
commitcaf744956d4c8c0ef358bdc3df2cdb10265c2ea8 (patch)
tree2b3f1991e58f949b1fb34a4948a74ca60e4d1dd7 /BaseTools/Source/Python/AutoGen/GenPcdDb.py
parentc14b58614ffb992dfc668966a19becb86614aafc (diff)
downloadedk2-caf744956d4c8c0ef358bdc3df2cdb10265c2ea8.tar.gz
edk2-caf744956d4c8c0ef358bdc3df2cdb10265c2ea8.tar.bz2
edk2-caf744956d4c8c0ef358bdc3df2cdb10265c2ea8.zip
BaseTools: Cleanup unneeded code
Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/AutoGen/GenPcdDb.py')
-rw-r--r--BaseTools/Source/Python/AutoGen/GenPcdDb.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/BaseTools/Source/Python/AutoGen/GenPcdDb.py b/BaseTools/Source/Python/AutoGen/GenPcdDb.py
index 2e05b77e14..25e4f7246e 100644
--- a/BaseTools/Source/Python/AutoGen/GenPcdDb.py
+++ b/BaseTools/Source/Python/AutoGen/GenPcdDb.py
@@ -1115,7 +1115,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
TokenSpaceGuid = GuidStructureStringToGuidValueName(TokenSpaceGuidStructure)
if Pcd.Type in PCD_DYNAMIC_EX_TYPE_SET:
if TokenSpaceGuid not in GuidList:
- GuidList += [TokenSpaceGuid]
+ GuidList.append(TokenSpaceGuid)
Dict['GUID_STRUCTURE'].append(TokenSpaceGuidStructure)
NumberOfExTokens += 1
@@ -1140,7 +1140,6 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
Pcd.TokenTypeList = ['PCD_DATUM_TYPE_' + Pcd.DatumType]
if len(Pcd.SkuInfoList) > 1:
-# Pcd.TokenTypeList += ['PCD_TYPE_SKU_ENABLED']
NumberOfSkuEnabledPcd += 1
SkuIdIndex = 1
@@ -1178,7 +1177,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
else:
EdkLogger.error("build", PCD_VALIDATION_INFO_ERROR,
"The PCD '%s.%s' Validation information defined in DEC file has incorrect format." % (Pcd.TokenSpaceGuidCName, Pcd.TokenCName))
- Pcd.TokenTypeList += ['PCD_TYPE_HII']
+ Pcd.TokenTypeList.append('PCD_TYPE_HII')
Pcd.InitString = 'INIT'
# Store all variable names of one HII PCD under different SKU to stringTable
# and calculate the VariableHeadStringIndex
@@ -1209,7 +1208,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
# store VariableGuid to GuidTable and get the VariableHeadGuidIndex
if VariableGuid not in GuidList:
- GuidList += [VariableGuid]
+ GuidList.append(VariableGuid)
Dict['GUID_STRUCTURE'].append(VariableGuidStructure)
VariableHeadGuidIndex = GuidList.index(VariableGuid)
@@ -1261,7 +1260,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
VariableDbValueList.append([VariableHeadGuidIndex, VariableHeadStringIndex, Sku.VariableOffset, VariableOffset, VariableRefTable, Sku.VariableAttribute])
elif Sku.VpdOffset != '':
- Pcd.TokenTypeList += ['PCD_TYPE_VPD']
+ Pcd.TokenTypeList.append('PCD_TYPE_VPD')
Pcd.InitString = 'INIT'
VpdHeadOffsetList.append(str(Sku.VpdOffset) + 'U')
VpdDbOffsetList.append(Sku.VpdOffset)
@@ -1273,7 +1272,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
continue
if Pcd.DatumType == TAB_VOID:
- Pcd.TokenTypeList += ['PCD_TYPE_STRING']
+ Pcd.TokenTypeList.append('PCD_TYPE_STRING')
Pcd.InitString = 'INIT'
if Sku.HiiDefaultValue != '' and Sku.DefaultValue == '':
Sku.DefaultValue = Sku.HiiDefaultValue
@@ -1322,7 +1321,7 @@ def CreatePcdDatabasePhaseSpecificAutoGen (Platform, DynamicPcdList, Phase):
StringTableSize += (StringTabLen)
else:
if "PCD_TYPE_HII" not in Pcd.TokenTypeList:
- Pcd.TokenTypeList += ['PCD_TYPE_DATA']
+ Pcd.TokenTypeList.append('PCD_TYPE_DATA')
if Sku.DefaultValue == 'TRUE':
Pcd.InitString = 'INIT'
else: