From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mx.groups.io with SMTP id smtpd.web08.39120.1655779645597642422 for ; Mon, 20 Jun 2022 19:47:25 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=TYfWGCYa; spf=pass (domain: intel.com, ip: 134.134.136.100, mailfrom: ray.ni@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1655779645; x=1687315645; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=Ajb6BYGg8gIN6QjR5leeGuzgq1Ngk0bIQLsF3JIA/8s=; b=TYfWGCYaouIf48dywH/tLcuK7ijjKzJ2LXARW2pVFTpDEm7OWxVpRYhn tV/KS/lhFPbgN4yvgbvKR9CTqyWH/FrG/JTfZbr6vZxgZQzXeAd/v/0Ie NLo9Gux8CYHfPNzB5NrY252Nnkyf0B/sjCRiTFZ0nA5vSNAsCY6E80QZa WWEvKcenTj7opgkHgWYU6QHZ+c1GfwTySq/RAgLvaITpNiu5nt9NdFQyS DrP50uqUT/0Tw2n3eMikuucob2v8ioJ/I5jbpNUbjp4kUdW5t/LRz0Qwa wwzUKiIeiE5rILEECvRf/yoah9tUL6E7+kr0I6RxOWNU1iceCnb4h7+lK g==; X-IronPort-AV: E=McAfee;i="6400,9594,10384"; a="344004376" X-IronPort-AV: E=Sophos;i="5.92,207,1650956400"; d="scan'208";a="344004376" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Jun 2022 19:47:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.92,207,1650956400"; d="scan'208";a="537875612" Received: from fmsmsx602.amr.corp.intel.com ([10.18.126.82]) by orsmga003.jf.intel.com with ESMTP; 20 Jun 2022 19:47:24 -0700 Received: from fmsmsx610.amr.corp.intel.com (10.18.126.90) by fmsmsx602.amr.corp.intel.com (10.18.126.82) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Mon, 20 Jun 2022 19:47:24 -0700 Received: from fmsedg602.ED.cps.intel.com (10.1.192.136) by fmsmsx610.amr.corp.intel.com (10.18.126.90) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Mon, 20 Jun 2022 19:47:24 -0700 Received: from NAM04-BN8-obe.outbound.protection.outlook.com (104.47.74.46) by edgegateway.intel.com (192.55.55.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Mon, 20 Jun 2022 19:47:24 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=e6VD3pTp2038zpIVbLA1dLa8EUAtuG98pbgfrZikTCXAHYaf5yHYGI6PduOJ4itBREjElCT6EWtdlkahgvYn5pukfcA9s5/rmwEj/kDHZNROeAXg9moN2GlqN+BQ1lGlOV010HASBul3DKvw6hCYzhjmfK1811uDrLBg/pE4mmUtOM4AwKwHWqhS1prKzQkfgXgSpQ/MFTJ2rSQ8TmfZPszAjnFmr5h16SScEoa7l6+cifKA6ZIDGsLHCu6zCc4wDC8dCTLBU9uGQCoNdZT2YGdxb8ojpkFcJ35AeQ+bdQmjFbd5q9C0s9+3APZ6S6T1aahHJx01ImHDOGjEvSJRvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=FOwBf2h+rMLq4xEEul5bzRPKqj8PH36HuMGx7hzD7xo=; b=W0oshaKSmU2Cg4R5mscQaXCKHVSXc0jABGPMuXlkl0tfKQIZnmKeJAyeO+E40s6yoDJVUKR4ODNyKJf/8mTdSkLg4RfJ01ZM5a/2Wa0fX8jnNF1xPrLZyo1tFF42UB2jYY6hnQN7sIIrySs0WXYAKSJQ68/hy/BqEtIa3A16C7lnYcSNo0XwxUAc3AuchwZGtBG7c66NKhbxFClvKe9O9Mjl0KHnepE1hazCNR5GWrjWjpfrYhQrrF4evdSj4Tj3ZnTmDWu14pZXCgzabgEcrci/frO1ArrFMdJWGvVuFQmVxLS5cYfY/GwFpuAqdSXcHZs0Mw/9sYvnKbPSbECS2A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from MWHPR11MB1631.namprd11.prod.outlook.com (2603:10b6:301:10::10) by CO6PR11MB5633.namprd11.prod.outlook.com (2603:10b6:303:13c::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5353.14; Tue, 21 Jun 2022 02:47:22 +0000 Received: from MWHPR11MB1631.namprd11.prod.outlook.com ([fe80::991b:97a0:7836:5174]) by MWHPR11MB1631.namprd11.prod.outlook.com ([fe80::991b:97a0:7836:5174%10]) with mapi id 15.20.5353.022; Tue, 21 Jun 2022 02:47:22 +0000 From: "Ni, Ray" To: "Guo, Gua" , "devel@edk2.groups.io" CC: "Dong, Guo" , "Feng, Bob C" Subject: Re: [PATCH] UefiPayloadPkg: UniversalPayloadBuild.py to support --pcd feature Thread-Topic: [PATCH] UefiPayloadPkg: UniversalPayloadBuild.py to support --pcd feature Thread-Index: AQHYhEjqP9h6KyT9pEukAxG5Ka3tmK1ZKKbg Date: Tue, 21 Jun 2022 02:47:22 +0000 Message-ID: References: In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 499c1bd6-614f-41dd-28aa-08da53305da9 x-ms-traffictypediagnostic: CO6PR11MB5633:EE_ x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: OLeqqvVfHgbZPmSEiX6dO0eampvPM0O9Jivl604AvqFV28iS259mKPWmePfjj+btmmGvP1L64qzMllmPaYOm0vpZKjn/OomyZ6riDxhrB9rx/bbWNljnPDHr7ET62/rgPT15clwlMY+y54ngFvj5v45ercINj4OJr1BapucPNcXhUDDHn51B6MeFNG5hHp0rbZF72hi7YZJswmIxLcCS+VA4I1B+DFE/zSWWThzRNQ60/qVhXJB9bPbuEcIyfzNYIaoXt+xp3uXgYDseHLsLJSkXRDd5QGlwru0v6ZDqGHbzoflFhSCZ8IQsOii85SRPupeckoIgCP0pXG1aAiy71owqYTTISOxQqx9pRWoQuJ/7vbD9SZsFUag4HFGt4g8IhKJshVWAvEDgt/I2/n4YrX3RzPcOjMYFtZezo89sG8umVIRXythhmz0sZi4ZfX73TidbnXT3UTSib5FCSRVU7lrZPaNWZQdu3Me12fwmkYHFz4AqO2YQP80Rjs47ame7B3Yue6xe1YZWLL8iAz96YETiTa1LzII3lhMfQJd8Ft0LMGb0NKSGBDPNuD9iG0rVODZgYvgxIM2x5eH+WAKYzRP93CAfB8SVko+D+CmT2YBc5/DB2FLpwzQDBxK2TOzJPaquUKBxbVedNq6/dzoTf3wCNKKX+pJfrxivRcBPdqNaRpmHi9iNTDIjV7jYCxyjI17GPFljLQD43IICnDDUYZI/i6pjIIDHqajZmbOFf+9riyk8VVauck8odciDfwFh3aMGiCI2HFV/bG52cIBWMHl84NixyLUGuUsUuolLToE= x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MWHPR11MB1631.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(376002)(39860400002)(136003)(366004)(396003)(346002)(71200400001)(110136005)(55016003)(38070700005)(33656002)(122000001)(26005)(66446008)(66476007)(9686003)(82960400001)(966005)(66556008)(107886003)(76116006)(54906003)(86362001)(41300700001)(316002)(64756008)(66946007)(52536014)(6506007)(8936002)(53546011)(38100700002)(4326008)(186003)(83380400001)(8676002)(478600001)(7696005)(2906002)(5660300002);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?jVqzMn1i+xo+WyB33RkKzobZGZNdNh9rTphgdVzIv3eN4wplSIJAZfQoJSY6?= =?us-ascii?Q?+lwPcMZXCrVO9pmQd1K+7a81yAvnWVLrFf0BTLdplgYprAJdcGIwC/XFM5m5?= =?us-ascii?Q?FTqXCXxNdEY5/1ha7omrHdzPk5qXNR21BN74zbTWrbtLJMmop2b/BLqwToRC?= =?us-ascii?Q?O/bCdkh0JeIzhcKlPSD9zXFhSLdgokFqTxVTkewas04KNX5C13dyAzwY+f2O?= =?us-ascii?Q?YanPAX2He12lcZ9ZyDk4aouxJodFSLg+wSFl/DDP+nS0QCIw5jC2Cy6wxSXw?= =?us-ascii?Q?3hlSD8zc+x/A13eoghwJLzRyav+LcunyVJh0KYSYJG3VanGWN009xiURc1Iq?= =?us-ascii?Q?4YXAfgtVbBfc0ta2ecs2HfSgu3p/zfUpzVFHJmJK3Dz8dnorByu5N0EhQ5ft?= =?us-ascii?Q?DXhwDMuHSqIFfLmain2kqk5zaYXPX52hcPbGYKoCJMssNoNLqM13SLaqCuJg?= =?us-ascii?Q?pFL/vp++q6nfDR1/ppdM/ccngMyL0BYa2nKWUv94dcCSl5BL1leai43Yu6bt?= =?us-ascii?Q?4IkmSAYwrlAhjSU333ReI2Dc6JZZD2ejIjBwh7CgIBXUBoVauwdopHfgJfTl?= =?us-ascii?Q?oKQaem3aZRcp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hz7Va?= =?us-ascii?Q?EWf2WpuqVLfNY5hWCiZxOXGDfz58qh4+EQ4s3vt/MzdONuJbycVBq2Sd8pnm?= =?us-ascii?Q?/1NaMB8Juowiz7OONygNFDDdykzBlDi+9wrEwNyGcaaKfCkLLJ4w3/xN8yvI?= =?us-ascii?Q?e+/kM7HOvCRatYiQHpHpLS21Q6lVN9La6VpoF/MacuPmtz98q6I37JqwVvN2?= =?us-ascii?Q?VXQtZTNNmkhLqT/viKuye2YgpzJ00SjBTAebid1Xv34NnL9lFetHQ/q7VF61?= =?us-ascii?Q?x59P5fHhPQ=3D=3D?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MWHPR11MB1631.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 499c1bd6-614f-41dd-28aa-08da53305da9 X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Jun 2022 02:47:22.0624 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: R8LQX8kSu2OOSB6Xse/Noe2zqCAfcoaXkSWKQE8XVCcAWbZyOO3Lixo0v1qtg8uBpsidd9OVNfAVCSzNiSnLEQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO6PR11MB5633 Return-Path: ray.ni@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Ray Ni > -----Original Message----- > From: Guo, Gua > Sent: Monday, June 20, 2022 9:56 AM > To: devel@edk2.groups.io > Cc: Guo, Gua ; Dong, Guo ; Ni, > Ray > Subject: [PATCH] UefiPayloadPkg: UniversalPayloadBuild.py to support --pc= d > feature >=20 > From: Gua Guo >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3955 >=20 > Currently, UPL freezed all PCD and only known UPL hob can hook DXE > Drivers behavior, add optional feature on UniversalPayloadBuild.py to > have another way to hook PCD value. >=20 > Cc: Guo Dong > Cc: Ray Ni > Signed-off-by: Gua Guo > --- > UefiPayloadPkg/UniversalPayloadBuild.py | 8 ++++++++ > 1 file changed, 8 insertions(+) >=20 > diff --git a/UefiPayloadPkg/UniversalPayloadBuild.py > b/UefiPayloadPkg/UniversalPayloadBuild.py > index 089d631b51..c71526e0a6 100644 > --- a/UefiPayloadPkg/UniversalPayloadBuild.py > +++ b/UefiPayloadPkg/UniversalPayloadBuild.py > @@ -82,6 +82,11 @@ def BuildUniversalPayload(Args, MacroList): > print("- Failed - Please check if LLVM is installed or if CLANG_= BIN is set > correctly") >=20 > sys.exit(1) >=20 >=20 >=20 > + Pcds =3D "" >=20 > + if (Args.pcd !=3D None): >=20 > + for PcdItem in Args.pcd: >=20 > + Pcds +=3D " --pcd {}".format (PcdItem) >=20 > + >=20 > Defines =3D "" >=20 > for key in MacroList: >=20 > Defines +=3D" -D {0}=3D{1}".format(key, MacroList[key]) >=20 > @@ -90,12 +95,14 @@ def BuildUniversalPayload(Args, MacroList): > # Building DXE core and DXE drivers as DXEFV. >=20 > # >=20 > BuildPayload =3D f"build -p {DscPath} -b {BuildTarget} -a X64 -t {To= olChain} -y > {PayloadReportPath} {Quiet}" >=20 > + BuildPayload +=3D Pcds >=20 > BuildPayload +=3D Defines >=20 > RunCommand(BuildPayload) >=20 > # >=20 > # Building Universal Payload entry. >=20 > # >=20 > BuildModule =3D f"build -p {DscPath} -b {BuildTarget} -a {BuildArch}= -m > {EntryModuleInf} -t {ElfToolChain} -y {ModuleReportPath} {Quiet}" >=20 > + BuildModule +=3D Pcds >=20 > BuildModule +=3D Defines >=20 > RunCommand(BuildModule) >=20 >=20 >=20 > @@ -128,6 +135,7 @@ def main(): > parser.add_argument("-D", "--Macro", action=3D"append", > default=3D["UNIVERSAL_PAYLOAD=3DTRUE"]) >=20 > parser.add_argument('-i', '--ImageId', type=3Dstr, help=3D'Specify p= ayload ID > (16 bytes maximal).', default =3D'UEFI') >=20 > parser.add_argument('-q', '--Quiet', action=3D'store_true', help=3D'= Disable all > build messages except FATAL ERRORS.') >=20 > + parser.add_argument("-p", "--pcd", action=3D"append") >=20 > MacroList =3D {} >=20 > args =3D parser.parse_args() >=20 > if args.Macro is not None: >=20 > -- > 2.31.1.windows.1