From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mx.groups.io with SMTP id smtpd.web11.5467.1575011047469534086 for ; Thu, 28 Nov 2019 23:04:07 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.93, mailfrom: chasel.chiu@intel.com) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Nov 2019 23:04:07 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,256,1571727600"; d="scan'208";a="234624875" Received: from kmsmsx154.gar.corp.intel.com ([172.21.73.14]) by fmsmga004.fm.intel.com with ESMTP; 28 Nov 2019 23:04:06 -0800 Received: from pgsmsx111.gar.corp.intel.com ([169.254.2.24]) by KMSMSX154.gar.corp.intel.com ([169.254.12.159]) with mapi id 14.03.0439.000; Fri, 29 Nov 2019 15:04:05 +0800 From: "Chiu, Chasel" To: "Kubacki, Michael A" , "devel@edk2.groups.io" CC: "Desimone, Nathaniel L" , "Gao, Liming" Subject: Re: [edk2-platforms][PATCH V2 39/47] MinPlatformPkg: Install advanced feature FVs by stage enabled Thread-Topic: [edk2-platforms][PATCH V2 39/47] MinPlatformPkg: Install advanced feature FVs by stage enabled Thread-Index: AQHVpZIvOxWruhdDVUuu+mNZzbFi+KehuzSQ Date: Fri, 29 Nov 2019 07:04:04 +0000 Message-ID: <3C3EFB470A303B4AB093197B6777CCEC505B1FA5@PGSMSX111.gar.corp.intel.com> References: <20191128021838.42640-1-michael.a.kubacki@intel.com> In-Reply-To: <20191128021838.42640-1-michael.a.kubacki@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZjRlZjQ2YmUtYmYyMy00NjNmLTkzYTItZDFlZDAxMWM3NzBkIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiXC9LNENSbTVaYWkwS0Y2eXo0Nk1wS0NFMFc0am12MUhURURLT21IbjBNYjl1TDVvYTZ5VkllcktTNmNUbmZFMXcifQ== x-ctpclassification: CTP_NT x-originating-ip: [172.30.20.206] MIME-Version: 1.0 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Chasel Chiu > -----Original Message----- > From: Kubacki, Michael A > Sent: Thursday, November 28, 2019 10:19 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > ; Gao, Liming > Subject: [edk2-platforms][PATCH V2 39/47] MinPlatformPkg: Install advance= d > feature FVs by stage enabled >=20 > This change updates the FvReportLib instance in MinPlatformPkg to only > install advanced feature firmware volumes if the advanced feature stage > should be active. >=20 > Cc: Chasel Chiu > Cc: Nate DeSimone > Cc: Liming Gao > Signed-off-by: Michael Kubacki > Reviewed-by: Nate DeSimone > --- > Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > | 1 + >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRepo > rtFvLib.inf | 1 + >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRepo > rtFvLib.c | 50 +++++++++++--------- > 3 files changed, 29 insertions(+), 23 deletions(-) >=20 > diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > index 21013cc87c..7f74ac9380 100644 > --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > @@ -272,6 +272,7 @@ SetCacheMtrrLib|Include/Library/SetCacheMtrrLib.h > # Stage 3 - boot to shell only > # Stage 4 - boot to OS > # Stage 5 - boot to OS with security boot enabled > + # Stage 6 - boot with advanced features enabled > # > gMinPlatformPkgTokenSpaceGuid.PcdBootStage|4|UINT8|0xF00000A0 >=20 > diff --git > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.inf > b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.inf > index 1ce3034fcc..ef03e110bd 100644 > --- > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.inf > +++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/ > +++ PeiReportFvLib.inf > @@ -30,6 +30,7 @@ > PeiReportFvLib.c >=20 > [Pcd] > + gMinPlatformPkgTokenSpaceGuid.PcdBootStage > ## CONSUMES > gMinPlatformPkgTokenSpaceGuid.PcdFspWrapperBootMode > ## CONSUMES > gMinPlatformPkgTokenSpaceGuid.PcdFlashAreaBaseAddress > ## CONSUMES > gMinPlatformPkgTokenSpaceGuid.PcdFlashAreaSize > ## CONSUMES > diff --git > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.c > b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.c > index b61587f6e3..0d805d6fe7 100644 > --- > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRe > portFvLib.c > +++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/ > +++ PeiReportFvLib.c > @@ -40,20 +40,22 @@ ReportPreMemFv ( > NULL, > 0 > ); > - DEBUG (( > - DEBUG_INFO, > - "Install FlashFvAdvancedPreMemory - 0x%x, 0x%x\n", > - PcdGet32 (PcdFlashFvAdvancedPreMemoryBase), > - PcdGet32 (PcdFlashFvAdvancedPreMemorySize) > - )); > - PeiServicesInstallFvInfo2Ppi ( > - &(((EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) PcdGet32 > (PcdFlashFvAdvancedPreMemoryBase))->FileSystemGuid), > - (VOID *) (UINTN) PcdGet32 (PcdFlashFvAdvancedPreMemoryBase), > - PcdGet32 (PcdFlashFvAdvancedPreMemorySize), > - NULL, > - NULL, > - 0 > - ); > + if (PcdGet8 (PcdBootStage) >=3D 6) { > + DEBUG (( > + DEBUG_INFO, > + "Install FlashFvAdvancedPreMemory - 0x%x, 0x%x\n", > + PcdGet32 (PcdFlashFvAdvancedPreMemoryBase), > + PcdGet32 (PcdFlashFvAdvancedPreMemorySize) > + )); > + PeiServicesInstallFvInfo2Ppi ( > + &(((EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) PcdGet32 > (PcdFlashFvAdvancedPreMemoryBase))->FileSystemGuid), > + (VOID *) (UINTN) PcdGet32 (PcdFlashFvAdvancedPreMemoryBase), > + PcdGet32 (PcdFlashFvAdvancedPreMemorySize), > + NULL, > + NULL, > + 0 > + ); > + } > } >=20 > VOID > @@ -122,15 +124,17 @@ ReportPostMemFv ( > NULL, > 0 > ); > - DEBUG ((DEBUG_INFO, "Install FlashFvAdvanced - 0x%x, 0x%x\n", > PcdGet32 (PcdFlashFvAdvancedBase), PcdGet32 (PcdFlashFvAdvancedSize))); > - PeiServicesInstallFvInfo2Ppi ( > - &(((EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) PcdGet32 > (PcdFlashFvAdvancedBase))->FileSystemGuid), > - (VOID *) (UINTN) PcdGet32 (PcdFlashFvAdvancedBase), > - PcdGet32 (PcdFlashFvAdvancedSize), > - NULL, > - NULL, > - 0 > - ); > + if (PcdGet8 (PcdBootStage) >=3D 6) { > + DEBUG ((DEBUG_INFO, "Install FlashFvAdvanced - 0x%x, 0x%x\n", > PcdGet32 (PcdFlashFvAdvancedBase), PcdGet32 (PcdFlashFvAdvancedSize))); > + PeiServicesInstallFvInfo2Ppi ( > + &(((EFI_FIRMWARE_VOLUME_HEADER *) (UINTN) PcdGet32 > (PcdFlashFvAdvancedBase))->FileSystemGuid), > + (VOID *) (UINTN) PcdGet32 (PcdFlashFvAdvancedBase), > + PcdGet32 (PcdFlashFvAdvancedSize), > + NULL, > + NULL, > + 0 > + ); > + } > } >=20 > // > -- > 2.16.2.windows.1