From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mx.groups.io with SMTP id smtpd.web10.10587.1635335740264509904 for ; Wed, 27 Oct 2021 04:55:40 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=pxBcNR6w; spf=pass (domain: intel.com, ip: 134.134.136.20, mailfrom: chasel.chiu@intel.com) X-IronPort-AV: E=McAfee;i="6200,9189,10149"; a="217313812" X-IronPort-AV: E=Sophos;i="5.87,186,1631602800"; d="scan'208";a="217313812" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Oct 2021 04:55:39 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.87,186,1631602800"; d="scan'208";a="724977336" Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by fmsmga005.fm.intel.com with ESMTP; 27 Oct 2021 04:55:39 -0700 Received: from fmsmsx610.amr.corp.intel.com (10.18.126.90) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12; Wed, 27 Oct 2021 04:55:38 -0700 Received: from fmsmsx604.amr.corp.intel.com (10.18.126.84) 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.2242.12; Wed, 27 Oct 2021 04:55:38 -0700 Received: from fmsedg602.ED.cps.intel.com (10.1.192.136) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12 via Frontend Transport; Wed, 27 Oct 2021 04:55:38 -0700 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (104.47.55.101) 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.2242.12; Wed, 27 Oct 2021 04:55:38 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kUBIdnDksiR4ZuYnLJN0XBt8OipA1DlXQuq22UcBqQOUUnL5V4m57xuUL1WXQJc7+UetHu7mNb82pVmuk5zM47KWdMfCDB+aB6/Oasp6JgouZk+y46XcfHfaksJor9SAPQxQiry0ulDkvhDe+IcOpgncVxhqDB4kkpyE4oXtYIVYcjP9kP18M3l/HnZ/RBY+qz6VRbUM32XMXlx8LK5dPYT7f3cZq89dDud2kgbfByz1M/62eRA1eRdDY7oqRGvlQaAQw7JQnb/Z3r0Bu/mR5lRa5/mAqSi677UtUDksSWf2FOBLYijR7FUyl6LumNOgcDYCMfUHsJdycIoExKc+tQ== 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=7asu5mbw+Wh5FkYytGSZkss2+nKoYkTSNO1G3q5OuZY=; b=DXbOd1M+sq49AHSL6vEQZ/L93BDltXGMlvcKrVLujfDH1Hm3CEBbUVziO8EZAYTfskP0WoH/4trBlVNRpVBJXRm4k2lQFgOrtM9xPFrH0nBIIDbk4RRmI3gC87okMH12z2YbDXaa9KVzQA8IOzWEHYwIQceeyuCg89JNC+1XKDZAHzymIcgzZmY1/TMQG8uUBYTyywteVKLf62iNTRfqvvPVkLFPBniVv5M5gpSFcSHsDUaLskoeC6+yyW2ADuAZdS1gVywtk0hhmZD/YTqPFPJrdEus1XTWMB689scDgey5UyDELK5pOkzuqY3gnkWAPP2zpVncSA9ext9hvaqkQw== 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=7asu5mbw+Wh5FkYytGSZkss2+nKoYkTSNO1G3q5OuZY=; b=pxBcNR6wXMouqq70esrAQ/koDLAtvVfZHwwQ1SKL+QV6wxAc7XQqO3fz/5/l5uafgHdR8SxaxWDc8+k+QGYcUqAtuOAbxmMjT0EHjJAUrcECUej6005nkjNStK7CsghTXup0F7IjQwXk5JtJZH0iv/XlGpJtB0lvblsjKgNV9TU= Received: from BN9PR11MB5483.namprd11.prod.outlook.com (2603:10b6:408:104::10) by BN6PR11MB4179.namprd11.prod.outlook.com (2603:10b6:405:76::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4649.14; Wed, 27 Oct 2021 11:55:37 +0000 Received: from BN9PR11MB5483.namprd11.prod.outlook.com ([fe80::dd1b:d932:9471:b8e]) by BN9PR11MB5483.namprd11.prod.outlook.com ([fe80::dd1b:d932:9471:b8e%2]) with mapi id 15.20.4649.014; Wed, 27 Oct 2021 11:55:37 +0000 From: "Chiu, Chasel" To: "devel@edk2.groups.io" , "Chiu, Chasel" CC: "Ma, Maurice" , "Desimone, Nathaniel L" , "Zeng, Star" Subject: Re: [edk2-devel] [PATCH] IntelFsp2Pkg/SplitFspBin.py: adopt FSP 2.3 specification. Thread-Topic: [edk2-devel] [PATCH] IntelFsp2Pkg/SplitFspBin.py: adopt FSP 2.3 specification. Thread-Index: AQHXykBSsYZATRSI+kaDSEF/MSXE1avmvnmg Date: Wed, 27 Oct 2021 11:55:37 +0000 Message-ID: References: <16B18613046C3205.3758@groups.io> In-Reply-To: <16B18613046C3205.3758@groups.io> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.6.200.16 authentication-results: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 3f3cb23b-96e3-42f4-9d89-08d99940b0de x-ms-traffictypediagnostic: BN6PR11MB4179: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:364; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: kGeSi1RXoG5KSLPGZFIRcPR7XO7Xjz0ufrSaFNmC/X8jvHa9Lms2XnfmAthcftW5HniVs1hfn8ECqXsgdk9VAM4tLcjfqe+605uAOr5d2U5f8vk8enEm2AJMZTUaTNc8EcvLLISICgI8phq8Mxt5c3my481Pd6lnl7I/AtbbbuwkHA8cOxJ7w5nxthrUvq82m+6xOzaISfGBNXH8wn/qKvaFPNkPLpudhen5JD5a2afZggeTjpkOmR3hlnj4jMXL1VF/Bql8xbrs4R57Gjkw8INbp/Ji1G6pVtlaeThhJvaXNVom+o+8QJ5Bh6DMLg7n4IinvjViFvqpGeLxtC7RiW9a9qFTAhl0d42N+p/kKljiZa5iiDYPLnWHqqyjlhlR1TTWk8qr1F0UIT+JbyphRHJRvhzeR9fL4os6qSeGc1PYZYf6I3gCORQaamNi88+6rhx2UL9VTUkR9cOE08Zb+GrNREMQRo10QTfs268w0aUi/4S5yuvnYLO4YXxcU3v44cVDu2t9sJb9Uop+/UdO/THhXHVA3j1OX5d6oNifPwv5L6N50LjoAAx1dX/sSJ+EXZZPucy7AVf+dhIihaAZ8USEmB3O91BH/4+Ovqh5HMuAdDljDclWzI+gkqaYGdd00aCPblWj0rclahAdL6K0bdbJcnaij+T/SSQOwax7zXvFEKMfrsOQrN3SLW+vogzmFiwaxmhSh1xpeRz163NnuPU2zXOaJczBOjv5wcscRNkCrnucsolDpKpil6PTmMc1FE5CUGPk3iJrk0UitYF0F8RE7cyX1ST4GGgMJKmguo+1xyVX9X8sUP5VYGL97s1dGjqmFgs+61iAFsabdAWnew== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN9PR11MB5483.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(366004)(110136005)(53546011)(38070700005)(186003)(86362001)(508600001)(52536014)(4326008)(54906003)(8936002)(2906002)(9686003)(7696005)(82960400001)(966005)(316002)(5660300002)(33656002)(6506007)(8676002)(107886003)(71200400001)(55016002)(83380400001)(64756008)(26005)(76116006)(19627235002)(66446008)(66946007)(122000001)(38100700002)(66476007)(66556008);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?iybwU29NZxKxEfeyUsM0L1XwwY7UiKMNWss1WahluiTG2RZWWzgdp95Pzchy?= =?us-ascii?Q?lGS0oxoCCuTbfQf8qlkmVOh00CwQ1F+WvBMc9QOGs/p4ZtJPXtdqRJE/ABAq?= =?us-ascii?Q?yI/euTw0pFlCsyBVeRPvjLrKk+nJX5xRoQFWYvXxurZIEtjnGCeRKz/FK9sV?= =?us-ascii?Q?Umim1JR/2B51+OumkSN3qzF4HB9khwOHPx0umoSf1+V+yBbfhQ2pyZSJMJdo?= =?us-ascii?Q?1pEOXOlCwZ325MFLkdwfHKPt3YmnM3GJS7DPGvT8DQbeLbMUZA6eLhVNFa57?= =?us-ascii?Q?kfqQgid7t7iY75h2C7u6bYleg7Jz+hTGX7tTTXCbDa6oMdfitey5p4S0Fjhf?= =?us-ascii?Q?fDf9k4IeCaEW7zDtGhTuQ6zm9667mvCbtcoUk7EvjnYs2cTkAYswrJ5f32/y?= =?us-ascii?Q?0/5G5qAttBBbo6/KX7orbiEY8qlc1UyjLkscaOy92kwMraaY1WmrF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8RJBgiAhHf86gK4trbWNCPUqg+5MFcFCI0?= =?us-ascii?Q?+7mXr92ySEF9zfscpMYKiL/O/XdbElT9wc2ciQCCaP5XfdA4U2CjMUDP/vr8?= =?us-ascii?Q?BvwVXTN+Im9GhcY6lm985cYaTmhcvCZnNxpScrprbQzjEqtUPFiTv78RBwJE?= =?us-ascii?Q?BQNGss6PPQj5FAfP1MIiS7ov+NiHHy4TGrQ81eOR3gaBWdByyejyx7LHYBhq?= =?us-ascii?Q?fnVn6Ntor0y5WWePY4HxcNRJ5jIjh85cdPLQ9aW6oRoA2oQ7fnNj5bAFXXPp?= =?us-ascii?Q?BILpgS9mwWdl6mwFfdiRb2c=3D?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BN9PR11MB5483.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3f3cb23b-96e3-42f4-9d89-08d99940b0de X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Oct 2021 11:55:37.1910 (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: xIohkCCFtPr86KiHdsjKhtdT7hA/XgiZ90R4zb5TKG+ugE5Bj60hEYgJTIhHlM1T5ZV8S1Lo6BQZZL4mYSwqIQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR11MB4179 Return-Path: chasel.chiu@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Patch pushed: https://github.com/tianocore/edk2/commit/9a95d11023ac2f2ee49a2958cf80658270= 442c42 Thanks, Chasel > -----Original Message----- > From: devel@edk2.groups.io On Behalf Of Chiu, Chas= el > Sent: Tuesday, October 26, 2021 4:06 PM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Ma, Maurice > ; Desimone, Nathaniel L > ; Zeng, Star > Subject: [edk2-devel] [PATCH] IntelFsp2Pkg/SplitFspBin.py: adopt FSP 2.3 > specification. >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3705 >=20 > FSP 2.3 has updated FSP_INFO_HEADER to support ExtendedImageRevision and > SplitFspBin.py needs to support it. >=20 > Also updated script to display integer value basing on length. >=20 > Cc: Maurice Ma > Cc: Nate DeSimone > Cc: Star Zeng > Signed-off-by: Chasel Chiu > --- > IntelFsp2Pkg/Tools/SplitFspBin.py | 66 > ++++++++++++++++++++++++++++++++++++++++++++---------------------- > 1 file changed, 44 insertions(+), 22 deletions(-) >=20 > diff --git a/IntelFsp2Pkg/Tools/SplitFspBin.py > b/IntelFsp2Pkg/Tools/SplitFspBin.py > index 24272e82af..20e329a76e 100644 > --- a/IntelFsp2Pkg/Tools/SplitFspBin.py > +++ b/IntelFsp2Pkg/Tools/SplitFspBin.py > @@ -1,6 +1,6 @@ > ## @ FspTool.py #-# Copyright (c) 2015 - 2020, Intel Corporation. All ri= ghts > reserved.
+# Copyright (c) 2015 - 2021, Intel Corporation. All rights > reserved.
# SPDX-License-Identifier: BSD-2-Clause-Patent # ##@@ -103,= 26 > +103,29 @@ class FSP_COMMON_HEADER(Structure): > class FSP_INFORMATION_HEADER(Structure): _fields_ =3D [- ('= Signature', > ARRAY(c_char, 4)),- ('HeaderLength', c_uint32),- ('= Reserved1', > c_uint16),- ('SpecVersion', c_uint8),- ('HeaderRev= ision', > c_uint8),- ('ImageRevision', c_uint32),- ('ImageId', > ARRAY(c_char, 8)),- ('ImageSize', c_uint32),- ('= ImageBase', > c_uint32),- ('ImageAttribute', c_uint16),- ('Componen= tAttribute', > c_uint16),- ('CfgRegionOffset', c_uint32),- ('CfgRegio= nSize', > c_uint32),- ('Reserved2', c_uint32),- ('TempRamI= nitEntryOffset', > c_uint32),- ('Reserved3', c_uint32),- ('No= tifyPhaseEntryOffset', > c_uint32),- ('FspMemoryInitEntryOffset', c_uint32),- > ('TempRamExitEntryOffset', c_uint32),- ('FspSiliconInitEntryOf= fset', > c_uint32)+ ('Signature', ARRAY(c_char, 4)),+ = ('HeaderLength', > c_uint32),+ ('Reserved1', c_uint16),+ = ('SpecVersion', > c_uint8),+ ('HeaderRevision', c_uint8),+ ('= ImageRevision', > c_uint32),+ ('ImageId', ARRAY(c_char, 8)),+= ('ImageSize', > c_uint32),+ ('ImageBase', c_uint32),+ = ('ImageAttribute', > c_uint16),+ ('ComponentAttribute', c_uint16),+ = ('CfgRegionOffset', > c_uint32),+ ('CfgRegionSize', c_uint32),+ = ('Reserved2', > c_uint32),+ ('TempRamInitEntryOffset', c_uint32),+ = ('Reserved3', > c_uint32),+ ('NotifyPhaseEntryOffset', c_uint32),+ > ('FspMemoryInitEntryOffset', c_uint32),+ ('TempRamExitEntryO= ffset', > c_uint32),+ ('FspSiliconInitEntryOffset', c_uint32),+ > ('FspMultiPhaseSiInitEntryOffset', c_uint32),+ ('ExtendedImageRevi= sion', > c_uint16),+ ('Reserved4', c_uint16) ] cl= ass > FSP_PATCH_TABLE(Structure):@@ -390,7 +393,26 @@ def OutputStruct (obj, > indent =3D 0, plen =3D 0): > if IsStrType (val): rep =3D HandleNameStr (v= al) elif > IsIntegerType (val):- rep =3D '0x%X' % val+ = if (key =3D=3D > 'ImageRevision'):+ FspImageRevisionMajor =3D ((v= al >> 24) & 0xFF)+ > FspImageRevisionMinor =3D ((val >> 16) & 0xFF)+ > FspImageRevisionRevision =3D ((val >> 8) & 0xFF)+ > FspImageRevisionBuildNumber =3D (val & 0xFF)+ rep =3D = '0x%08X' % val+ > elif (key =3D=3D 'ExtendedImageRevision'):+ FspImageRe= visionRevision > |=3D (val & 0xFF00)+ FspImageRevisionBuildNumber |=3D = ((val << 8) & > 0xFF00)+ rep =3D "0x%04X ('%02X.%02X.%04X.%04X')" % (v= al, > FspImageRevisionMajor, FspImageRevisionMinor, FspImageRevisionRevision, > FspImageRevisionBuildNumber)+ elif field[1] =3D=3D c_uint6= 4:+ > rep =3D '0x%016X' % val+ elif field[1] =3D=3D c_uint32:+ = rep =3D > '0x%08X' % val+ elif field[1] =3D=3D c_uint16:+ = rep =3D '0x%04X' % > val+ elif field[1] =3D=3D c_uint8:+ rep= =3D '0x%02X' % val+ > else:+ rep =3D '0x%X' % val elif isinstanc= e(val, c_uint24): > rep =3D '0x%X' % val.get_value() elif 'c_ubyte_Array' in str(= type(val)):-- > 2.28.0.windows.1 >=20 >=20 >=20 > -=3D-=3D-=3D-=3D-=3D-=3D > Groups.io Links: You receive all messages sent to this group. > View/Reply Online (#82675): https://edk2.groups.io/g/devel/message/82675 > Mute This Topic: https://groups.io/mt/86597871/1777047 > Group Owner: devel+owner@edk2.groups.io > Unsubscribe: https://edk2.groups.io/g/devel/unsub [chasel.chiu@intel.com]= -=3D- > =3D-=3D-=3D-=3D-=3D >=20