From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.151; helo=mga17.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 426F021959CB2 for ; Wed, 29 Aug 2018 05:41:48 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Aug 2018 05:41:48 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,303,1531810800"; d="scan'208";a="70012811" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga006.jf.intel.com with ESMTP; 29 Aug 2018 05:41:28 -0700 Received: from fmsmsx118.amr.corp.intel.com (10.18.116.18) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 29 Aug 2018 05:41:28 -0700 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by fmsmsx118.amr.corp.intel.com (10.18.116.18) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 29 Aug 2018 05:41:27 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.143]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.150]) with mapi id 14.03.0319.002; Wed, 29 Aug 2018 20:41:26 +0800 From: "Gao, Liming" To: "Feng, Bob C" , "edk2-devel@lists.01.org" Thread-Topic: [Patch] BaseTools: Dynamic Pcd value override from command line. Thread-Index: AQHUP3UKohpNyHv/hE6mZdkMP1+vjKTWrECA Date: Wed, 29 Aug 2018 12:41:25 +0000 Message-ID: <4A89E2EF3DFEDB4C8BFDE51014F606A14E2EAB8C@SHSMSX104.ccr.corp.intel.com> References: <20180829084759.1032-1-bob.c.feng@intel.com> In-Reply-To: <20180829084759.1032-1-bob.c.feng@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNjc0ZTAxYWUtOTM2My00ODBkLThlNjAtMzBkM2Q3ZDAyNDU5IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTFpYUjVVUlAwb3Z2dGRcL1RWdzlrWDMybFdoNmFGVGxSczVuVWY0RTRRZU1pOVo3OUpqbm9WTFwvV0NYWFlUeURiIn0= dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [Patch] BaseTools: Dynamic Pcd value override from command line. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Aug 2018 12:41:49 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Liming Gao > -----Original Message----- > From: Feng, Bob C > Sent: Wednesday, August 29, 2018 4:48 PM > To: edk2-devel@lists.01.org > Cc: Feng, Bob C ; Gao, Liming > Subject: [Patch] BaseTools: Dynamic Pcd value override from command line. >=20 > Fixed the pcd value override issue when Dynamic Pcd is from > command line but is not list in Dsc file. >=20 > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Bob Feng > Cc: Liming Gao > --- > BaseTools/Source/Python/Workspace/DscBuildData.py | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) >=20 > diff --git a/BaseTools/Source/Python/Workspace/DscBuildData.py b/BaseTool= s/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 =3D self.DecPcds.get((Name, Guid)) > if PcdInDec: > PcdInDec.PcdValueFromComm =3D NoFiledValues[(Guid, N= ame)][0] > if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PC= D_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] =3D copy.deepcopy(PcdInDec= ) > self.Pcds[Name, Guid].DefaultValue =3D NoFiledVa= lues[( Guid, Name)][0] > + if PcdInDec.Type in [self._PCD_TYPE_STRING_[MODEL_PC= D_DYNAMIC], > + self._PCD_TYPE_STRING_[MODEL_PCD= _DYNAMIC_EX]]: > + self.Pcds[Name, Guid].SkuInfoList =3D {TAB_DEFAU= LT:SkuInfoClass(TAB_DEFAULT, > self.SkuIds[TAB_DEFAULT][0], '', '', '', '', '', NoFiledValues[( Guid, Na= me)][0])} > return AllPcds >=20 > def OverrideByFdfOverAll(self,AllPcds): >=20 > if GlobalData.gFdfParser is None: > -- > 2.16.2.windows.1