* [Patch] BaseTools: Dynamic Pcd value override from command line.
@ 2018-08-29 8:47 BobCF
2018-08-29 12:41 ` Gao, Liming
0 siblings, 1 reply; 2+ messages in thread
From: BobCF @ 2018-08-29 8:47 UTC (permalink / raw)
To: edk2-devel; +Cc: Bob Feng, Liming Gao
Fixed the pcd value override issue when Dynamic Pcd is from
command line but is not list in Dsc file.
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/Workspace/DscBuildData.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/BaseTools/Source/Python/Workspace/DscBuildData.py b/BaseTools/Source/Python/Workspace/DscBuildData.py
index 748452623f..d553536961 100644
--- a/BaseTools/Source/Python/Workspace/DscBuildData.py
+++ b/BaseTools/Source/Python/Workspace/DscBuildData.py
@@ -1268,13 +1268,18 @@ class DscBuildData(PlatformBuildClassObject):
PcdInDec = self.DecPcds.get((Name, Guid))
if PcdInDec:
PcdInDec.PcdValueFromComm = NoFiledValues[(Guid, Name)][0]
if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PCD_FIXED_AT_BUILD],
self._PCD_TYPE_STRING_[MODEL_PCD_PATCHABLE_IN_MODULE],
- self._PCD_TYPE_STRING_[MODEL_PCD_FEATURE_FLAG]]:
+ self._PCD_TYPE_STRING_[MODEL_PCD_FEATURE_FLAG],
+ self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC],
+ self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC_EX]]:
self.Pcds[Name, Guid] = copy.deepcopy(PcdInDec)
self.Pcds[Name, Guid].DefaultValue = NoFiledValues[( Guid, Name)][0]
+ if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC],
+ self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC_EX]]:
+ self.Pcds[Name, Guid].SkuInfoList = {TAB_DEFAULT:SkuInfoClass(TAB_DEFAULT, self.SkuIds[TAB_DEFAULT][0], '', '', '', '', '', NoFiledValues[( Guid, Name)][0])}
return AllPcds
def OverrideByFdfOverAll(self,AllPcds):
if GlobalData.gFdfParser is None:
--
2.16.2.windows.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Patch] BaseTools: Dynamic Pcd value override from command line.
2018-08-29 8:47 [Patch] BaseTools: Dynamic Pcd value override from command line BobCF
@ 2018-08-29 12:41 ` Gao, Liming
0 siblings, 0 replies; 2+ messages in thread
From: Gao, Liming @ 2018-08-29 12:41 UTC (permalink / raw)
To: Feng, Bob C, edk2-devel@lists.01.org
Reviewed-by: Liming Gao <liming.gao@intel.com>
> -----Original Message-----
> From: Feng, Bob C
> Sent: Wednesday, August 29, 2018 4:48 PM
> To: edk2-devel@lists.01.org
> Cc: Feng, Bob C <bob.c.feng@intel.com>; Gao, Liming <liming.gao@intel.com>
> Subject: [Patch] BaseTools: Dynamic Pcd value override from command line.
>
> Fixed the pcd value override issue when Dynamic Pcd is from
> command line but is not list in Dsc file.
>
> 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/Workspace/DscBuildData.py | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/BaseTools/Source/Python/Workspace/DscBuildData.py b/BaseTools/Source/Python/Workspace/DscBuildData.py
> index 748452623f..d553536961 100644
> --- a/BaseTools/Source/Python/Workspace/DscBuildData.py
> +++ b/BaseTools/Source/Python/Workspace/DscBuildData.py
> @@ -1268,13 +1268,18 @@ class DscBuildData(PlatformBuildClassObject):
> PcdInDec = self.DecPcds.get((Name, Guid))
> if PcdInDec:
> PcdInDec.PcdValueFromComm = NoFiledValues[(Guid, Name)][0]
> if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PCD_FIXED_AT_BUILD],
> self._PCD_TYPE_STRING_[MODEL_PCD_PATCHABLE_IN_MODULE],
> - self._PCD_TYPE_STRING_[MODEL_PCD_FEATURE_FLAG]]:
> + self._PCD_TYPE_STRING_[MODEL_PCD_FEATURE_FLAG],
> + self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC],
> + self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC_EX]]:
> self.Pcds[Name, Guid] = copy.deepcopy(PcdInDec)
> self.Pcds[Name, Guid].DefaultValue = NoFiledValues[( Guid, Name)][0]
> + if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC],
> + self._PCD_TYPE_STRING_[MODEL_PCD_DYNAMIC_EX]]:
> + self.Pcds[Name, Guid].SkuInfoList = {TAB_DEFAULT:SkuInfoClass(TAB_DEFAULT,
> self.SkuIds[TAB_DEFAULT][0], '', '', '', '', '', NoFiledValues[( Guid, Name)][0])}
> return AllPcds
>
> def OverrideByFdfOverAll(self,AllPcds):
>
> if GlobalData.gFdfParser is None:
> --
> 2.16.2.windows.1
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-08-29 12:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-29 8:47 [Patch] BaseTools: Dynamic Pcd value override from command line BobCF
2018-08-29 12:41 ` Gao, Liming
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox