From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mx.groups.io with SMTP id smtpd.web08.5123.1607513839641127215 for ; Wed, 09 Dec 2020 03:37:19 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=Tal5mT9R; spf=pass (domain: intel.com, ip: 192.55.52.115, mailfrom: star.zeng@intel.com) IronPort-SDR: l17zqz7GQGrnfwvj5sK/0fdZv6VbA3fQUzxsLvfhWyMCEB+lIVsY7/rywzTnCzI6qlE1HpccGh FsDpL+0HtoYA== X-IronPort-AV: E=McAfee;i="6000,8403,9829"; a="173303456" X-IronPort-AV: E=Sophos;i="5.78,405,1599548400"; d="scan'208";a="173303456" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Dec 2020 03:37:18 -0800 IronPort-SDR: mlF+p0RRWYDGf6WotfrR4S+rc5OxvdRH4IiGfSUnCJgVRnPMzsJ0y6/GmfPvJ/4yAlV75EHHoU m3mNyYTqYY9Q== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.78,405,1599548400"; d="scan'208";a="337959857" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by orsmga006.jf.intel.com with ESMTP; 09 Dec 2020 03:37:18 -0800 Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Wed, 9 Dec 2020 03:37:18 -0800 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Wed, 9 Dec 2020 03:37:17 -0800 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5 via Frontend Transport; Wed, 9 Dec 2020 03:37:17 -0800 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.172) by edgegateway.intel.com (134.134.137.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.1713.5; Wed, 9 Dec 2020 03:37:17 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=H1E3kUOCGWmT29bPgmI/4Mrjhl1jHFoDIr+kejS83o36FwG6RXV2k1U07ImSI60P0p2WGXbZFWwP4Y1Jm/Urhpn7dsvSHzJk7+OK2/0iu0vKYsOBaY2/8WQmMKirE2HLKsVA54mgrvJ2Qg9HJwCT6XXf7OnZQ+DLSWzUp7i1F+OSF3Nx5ZKt97D7zWz1e8EvkaBw9dVP51NvDm14fJ4Ql+BOD07oGZM0wMrAEObAnSZR1EN4fQkmDkbfQJw375T9gs8bJodKE1QCz8uTXS3QY7S1zQXkW9Un/HPl2nxQtKZRduDDP8pNBvoL8cfuW0JpcaukZLeZYwNg71klO6nilQ== 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-SenderADCheck; bh=3aFTrReMFX3PTgZHLp34JEcfc88ovuJnRdafc3BZ12o=; b=JVNG/oP/l0nrMO2t8+nTshAEIW2OrvTddmgedjBewjSBZ7v4+WMBhfbnTl4kTwwMv3LdAwv4c3Ck6EhGg9ye7pQ73NvtpsTTiMMLkPmgjpjBScY4trGCdO+yNkjneWB+PJshskLlBFAUIRTPTCg9Kxo5zSQHSBnKNTd0MIyatX+DFKAT3noKYxwjZOJglO9wHttlKfFiFwjz/3WVG0duT9HLJvJNGC9OiMfZUxyuC3HHX+oICXG7cjh2Hn4DQ+cr4UpMNeml0YwSnvM0ehhE/gliOVPB1HYAkJi36xmJ7/UOkU5UXkqanhqt483O3a26r0HUo/0nFWVXgzscTAxexg== 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3aFTrReMFX3PTgZHLp34JEcfc88ovuJnRdafc3BZ12o=; b=Tal5mT9RETYvRgbNgInKqXcOgjrjpeX8yWJWlsv6QFnoK1vigLJaB+kFy+0OtZOTaS91tD+I5BeY8DZ1QPD/COnmLTDhbvEPEQbZNy2tEPQn7Zrc/OrHpW/dnJFjr0NJ7g11jDzfvEUl0v7RkXlHRcwIiVF8S1qfTxP7NVttLA4= Received: from DM6PR11MB4058.namprd11.prod.outlook.com (2603:10b6:5:193::13) by DM6PR11MB2587.namprd11.prod.outlook.com (2603:10b6:5:c3::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3611.25; Wed, 9 Dec 2020 11:37:16 +0000 Received: from DM6PR11MB4058.namprd11.prod.outlook.com ([fe80::409a:9424:2f64:d205]) by DM6PR11MB4058.namprd11.prod.outlook.com ([fe80::409a:9424:2f64:d205%3]) with mapi id 15.20.3654.013; Wed, 9 Dec 2020 11:37:16 +0000 From: "Zeng, Star" To: "Chiu, Chasel" , "devel@edk2.groups.io" CC: "Chiu, Chasel" , "Ma, Maurice" , "Desimone, Nathaniel L" , "Zeng, Star" Subject: Re: [PATCH] IntelFsp2Pkg/GenCfgOpt.py: Incremental build with UPD in sub DSC. Thread-Topic: [PATCH] IntelFsp2Pkg/GenCfgOpt.py: Incremental build with UPD in sub DSC. Thread-Index: AQHWzQgp46jOWbEJQkaBC1q60JX3EqnupR1w Date: Wed, 9 Dec 2020 11:37:15 +0000 Message-ID: References: <20201208021553.1348-1-chasel.chiu@intel.com> In-Reply-To: <20201208021553.1348-1-chasel.chiu@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [192.198.147.202] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f778b1fe-0610-4b6a-4045-08d89c36c767 x-ms-traffictypediagnostic: DM6PR11MB2587: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:4714; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: ai+OpRJX2xuRV11mDLBLGtQuphxBbTKCbTF1QYVYbX7YH30u/WbX+oa3QyJzLbXt+aHxA4BTQrrGZ2ORlQnY7h3ERz0ERTKq+QBxV+LclGUtpleTaN+PtFYdHK71LbEmRIj9gNXJ+OCqCtGha1uiBIaNLnXaEkXreH3FzPJAq0uhum4sFTkT8CGQchIvgdDHkOpey2/fpP921Qo4rEEB9/7X3E7LDpQsr6CZRodaClBqRB1Q8eJedk95myF45QhhpUWs0wahlI/8q5jzaSslVoVF6WhOsqGR5dAf7VK7ZqK4NLPsgezHfI2Q0Z5HFn+UBXhWXDZRI0HJPJ5RGNV81/xmWHVYTE1PdZf8f8drOV60BqescT9MRGp9w/quk7HvQr1s2Wao9d1xOzlaVV7ikg== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR11MB4058.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(136003)(346002)(366004)(376002)(33656002)(110136005)(66946007)(6506007)(54906003)(26005)(53546011)(508600001)(8676002)(186003)(19627235002)(7696005)(52536014)(76116006)(107886003)(66556008)(55016002)(71200400001)(5660300002)(8936002)(966005)(64756008)(86362001)(4326008)(66476007)(83380400001)(2906002)(66446008)(9686003);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?UWuEUH2Ee0Zhwl4qN5sl9vIdn+QA7OHa6r/gRIsHXdVZTzCaWGVwHJybBgvu?= =?us-ascii?Q?OIX+9uE2R2QS42fH1QA59+El+cWWknNm9nWcWofwQIyoM6U3nNWT8GPZQ2NJ?= =?us-ascii?Q?m5FJLmfEcWzI5mGWVic98Mv+lmIhRQPutfX/KQcIgUwGLnEsqAidl+vnwr1s?= =?us-ascii?Q?wwhPi7RnutinCN/+1Mbtnc3L7iSy6WJF1ZJmYNsKnIQahqiUPtGrVblZN2ln?= =?us-ascii?Q?XqqYR6PYxGzn0FfqYi/QFtZ86vHA053Zsc1vdSLwKHRtlGFthsNz8/M7fy+Q?= =?us-ascii?Q?iD7bgk/iEcJNTq6/aFY7qi/ytwMlgnWSwePFRnn6ZJgKr12E5WfpY+earfJ6?= =?us-ascii?Q?PaxjD46Ex5RiqhfMMBZiEiydoC8KHNwD694szgR8NzfR1h7c1hGqwu+TlHmp?= =?us-ascii?Q?pjGJqdsR0BRInxAI3WmvCQ12Q2vTi3MOFBqITITbz6cy3xPJBa+kmZlQOXQd?= =?us-ascii?Q?w6/BkKSqWXPrrfcQQcTNCdIGt8pwAZKrYyb2nl2UfN3HJkJo/mIGFz0JHPh2?= =?us-ascii?Q?4/f06zs5AlZ8rIYnekdz/BGw6FDsiG+DKaegGsu55UT2HzY/LMEl2mR3oxHe?= =?us-ascii?Q?hFb4n7i8of2syUfru6O0gkc4Oe2jmpqX/2EwZjVdoSdIDez+iD9Hbae9FfPi?= =?us-ascii?Q?kRZV8G1nanke74HNcUs7KUdZl5LOAXIK8N3V5h6izLCZSK9c5P3SUp/N6nNl?= =?us-ascii?Q?P6FbfqA9IKXRB1+fO+cDJpFYkjWDXrd4nymm/2QLHLVYUzIzD9fSZ5VLYEKb?= =?us-ascii?Q?hNQu+MSg90Vzcz9UE1EdSmVpsRjTvLAH5S+n8VHWP5xaMG3Js2AfXY4qpoF/?= =?us-ascii?Q?qzBY8GVyPcsD2g6B6Sav2f+z7BLOTmsDpodiDCGax53dpNIXLqsaMHrwZxLH?= =?us-ascii?Q?AIRuC15RqAO/afV9nXwk4Y6YdDgH37Ibl0ZWSpKHklokrHYybm+Vf1r9UVHM?= =?us-ascii?Q?frLw6NhvxDudvB2W87XHgyImjJ4LgoIV1A3dr/0pzBqg70Wux9SxGJLVQnaq?= =?us-ascii?Q?XD6h?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR11MB4058.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f778b1fe-0610-4b6a-4045-08d89c36c767 X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Dec 2020 11:37:15.8865 (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: HXBvc0HZRgCbpflRpmGmx7a761KbK4I5N9R2GrcLaTRO/fn7zsgIZbaI2CsgXgzT1Rg6a8GQaDomCQhsT1I/TQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB2587 Return-Path: star.zeng@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Star Zeng -----Original Message----- From: Chasel Chiu =20 Sent: Tuesday, December 8, 2020 10:16 AM To: devel@edk2.groups.io Cc: Chiu, Chasel ; Ma, Maurice ; Desimone, Nathaniel L ; Zeng, Star Subject: [PATCH] IntelFsp2Pkg/GenCfgOpt.py: Incremental build with UPD in s= ub DSC. REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3107 Current script only compares main DSC and output file datetime to determine if re-generation required or not. When UPD defined in sub DSC and was modified current script cannot detect and will not re-generate output files which caused incremental build issue. Since UPD can be defined in any sub DSC the script has been updated to compare all DSC datetime with output files to determine re-generation is needed or not. Cc: Maurice Ma Cc: Nate DeSimone Cc: Star Zeng Signed-off-by: Chasel Chiu --- IntelFsp2Pkg/Tools/GenCfgOpt.py | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/IntelFsp2Pkg/Tools/GenCfgOpt.py b/IntelFsp2Pkg/Tools/GenCfgOpt= .py index af7e14a10a..a0b8bba81e 100644 --- a/IntelFsp2Pkg/Tools/GenCfgOpt.py +++ b/IntelFsp2Pkg/Tools/GenCfgOpt.py @@ -313,6 +313,7 @@ EndList self._DscFile =3D '' self._FvDir =3D '' self._MapVer =3D 0 + self._DscTime =3D 0 =20 def ParseMacros (self, MacroDefStr): # ['-DABC=3D1', '-D', 'CFG_DEBUG=3D1', '-D', 'CFG_OUTDIR=3DBuild'] @@ -423,6 +424,9 @@ EndList self._DscFile =3D DscFile self._FvDir =3D FvDir =20 + # Initial DSC time is parent DSC time. + self._DscTime =3D os.path.getmtime(DscFile) + IsDefSect =3D False IsPcdSect =3D False IsUpdSect =3D False @@ -530,6 +534,12 @@ EndList if IncludeDsc =3D=3D None: print("ERROR: Cannot open file= '%s'" % IncludeFilePath) raise SystemExit + + # Update DscTime when newer DSC ti= me found. + CurrentDscTime =3D os.path.getmtim= e(os.path.realpath(IncludeDsc.name)) + if CurrentDscTime > self._DscTime: + self._DscTime =3D CurrentDscTi= me + NewDscLines =3D IncludeDsc.readlin= es() IncludeDsc.close() DscLines =3D NewDscLines + DscLine= s @@ -815,9 +825,8 @@ EndList if not os.path.exists(OutPutFile): NoFileChange =3D False else: - DscTime =3D os.path.getmtime(self._DscFile) OutputTime =3D os.path.getmtime(OutPutFile) - if DscTime > OutputTime: + if self._DscTime > OutputTime: NoFileChange =3D False return NoFileChange =20 --=20 2.28.0.windows.1