From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.20, mailfrom: yi.qian@intel.com) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by groups.io with SMTP; Thu, 09 May 2019 06:19:42 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 May 2019 06:19:41 -0700 X-ExtLoop1: 1 Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by fmsmga006.fm.intel.com with ESMTP; 09 May 2019 06:19:41 -0700 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 9 May 2019 06:19:41 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.249]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.18]) with mapi id 14.03.0415.000; Thu, 9 May 2019 21:19:39 +0800 From: "Qian, Yi" To: "Kinney, Michael D" , "devel@edk2.groups.io" CC: "Sun, Zailiang" Subject: Re: [Patch 06/16] Vlv2TbltDevicePkg: Find UEFI Shell using gUefiShellFileGuid Thread-Topic: [Patch 06/16] Vlv2TbltDevicePkg: Find UEFI Shell using gUefiShellFileGuid Thread-Index: AQHVBiARQWuwaDQVRUWFs24fg3plcKZix27A Date: Thu, 9 May 2019 13:19:38 +0000 Message-ID: References: <20190509043111.15272-1-michael.d.kinney@intel.com> <20190509043111.15272-7-michael.d.kinney@intel.com> In-Reply-To: <20190509043111.15272-7-michael.d.kinney@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Return-Path: yi.qian@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed by Qian, Yi Thanks QianYi -----Original Message----- From: Kinney, Michael D=20 Sent: Thursday, May 9, 2019 12:31 PM To: devel@edk2.groups.io Cc: Sun, Zailiang ; Qian, Yi Subject: [Patch 06/16] Vlv2TbltDevicePkg: Find UEFI Shell using gUefiShell= FileGuid Remove use of PCD PcdShellFile from the IntelFrameworkModulePkg and instea= d use gUefiShellFileGuid to find the UEFI Shell in an FV. Cc: Zailiang Sun Cc: Yi Qian Signed-off-by: Michael D Kinney --- Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c | 4 ++-- .../Library/PlatformBdsLib/PlatformBdsLib.inf | 10 ++++++---- .../Library/GenericBdsLib/BdsBoot.c | 8 ++++---- .../Library/GenericBdsLib/GenericBdsLib.inf | 5 +++-- 4 files changed, 15 insertions(+), 12 deletions(-) diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c b/Vlv2= TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c index 0f0e15c64a..e86c6b3e2e 100644 --- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c +++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c @@ -1356,7 +1356,7 @@ PlatformBdsLibEnumerateAllBootOption ( =20 Status =3D Fv->ReadFile ( Fv, - PcdGetPtr(PcdShellFile), + &gUefiShellFileGuid, NULL, &Size, &Type, @@ -1528,7 +1528,7 @@ PlatformBdsLibEnumerateAllBootOption ( =20 Status =3D Fv->ReadFile ( Fv, - PcdGetPtr(PcdShellFile), + &gUefiShellFileGuid, NULL, &Size, &Type, diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf b= /Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf index 5831569fae..d3bef0fa39 100644 --- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf +++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/PlatformBdsLib.inf @@ -1,11 +1,13 @@ #/** @file # Component name for module PlatformBootManagerLib # -# Copyright (c) 20= 08 - 2016, Intel Corporation. All rights reserved.
-# = +# Copyright (c) 2008 - 2019, Intel Corporation. All rights=20 +reserved.
# + # SPDX-License-Identifier: BSD-2-Clause-Patent =20 -# = +# + # # # @@ -97,6 +99,7 @@ [Guids] gEfiNormalSetupGuid gEfiPartTypeSystemPartGuid gEfiEndOfDxeEventGroupGuid + gUefiShellFileGuid =20 [Pcd] gEfiSignedCapsulePkgTokenSpaceGuid.PcdEdkiiRsa2048Sha256TestPublicKeyFi= leGuid @@ -111,7 +114,6 @@ [Pcd] gPlatformModuleTokenSpaceGuid.PcdFlashFvShellSize gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile - gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile gPlatformModuleTokenSpaceGuid.PcdIFWISigBaseAddress gEfiMdeModulePkgTokenSpaceGuid.PcdConOutRow gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn diff --git a/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/Ge= nericBdsLib/BdsBoot.c b/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/= Library/GenericBdsLib/BdsBoot.c index b875041880..3034853695 100644 --- a/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/GenericBd= sLib/BdsBoot.c +++ b/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/Generic +++ BdsLib/BdsBoot.c @@ -1,7 +1,7 @@ /** @file BDS Lib functions which relate with create or process the boot option. =20 -Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2004 - 2019, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -2342,7 +2342,7 @@ BdsLibBootViaBootOption ( // // If the boot option point to Internal FV shell, make sure it is val= id // - Status =3D BdsLibUpdateFvFileDevicePath (&DevicePath, PcdGetPtr(PcdSh= ellFile)); + Status =3D BdsLibUpdateFvFileDevicePath (&DevicePath,=20 + &gUefiShellFileGuid); if (!EFI_ERROR(Status)) { if (Option->DevicePath !=3D NULL) { FreePool(Option->DevicePath); @@ -3544,7 +3544,7 @@ BdsLibEnumerateAllBootOption ( =20 Status =3D Fv->ReadFile ( Fv, - PcdGetPtr(PcdShellFile), + &gUefiShellFileGuid, NULL, &Size, &Type, @@ -3629,7 +3629,7 @@ BdsLibBuildOptionFromShell ( // // Build the shell device path // - EfiInitializeFwVolDevicepathNode (&ShellNode, PcdGetPtr(PcdShellFile)); + EfiInitializeFwVolDevicepathNode (&ShellNode, &gUefiShellFileGuid); =20 DevicePath =3D AppendDevicePathNode (DevicePath, (EFI_DEVICE_PATH_PROTO= COL *) &ShellNode); =20 diff --git a/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/Ge= nericBdsLib/GenericBdsLib.inf b/Vlv2TbltDevicePkg/Override/IntelFrameworkMo= dulePkg/Library/GenericBdsLib/GenericBdsLib.inf index a978b5cbfa..e3c8a6fa27 100644 --- a/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/GenericBd= sLib/GenericBdsLib.inf +++ b/Vlv2TbltDevicePkg/Override/IntelFrameworkModulePkg/Library/Generic +++ BdsLib/GenericBdsLib.inf @@ -6,7 +6,7 @@ # 2) BDS boot device connect interface; # 3) BDS Misc interfaces for m= ainting boot variable, ouput string, etc. # -# Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.
+# Copyright (c) 2007 - 2019, Intel Corporation. All rights=20 +reserved.
# SPDX-License-Identifier: BSD-2-Clause-Patent # ## @@ -43,6 +43,7 @@ = [Packages] MdeModulePkg/MdeModulePkg.dec IntelFrameworkPkg/IntelFrameworkPkg.dec IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec + ShellPkg/ShellPkg.dec =20 [LibraryClasses] DevicePathLib @@ -98,6 +99,7 @@ [Guids] ## SOMETIMES_CONSUMES ## Variable:L"LegacyDevOrder" gEfiLegacyDevOrderVariableGuid gEdkiiStatusCodeDataTypeVariableGuid ## SOMETIMES_CONSUMES ## = GUID + gUefiShellFileGuid =20 [Protocols] gEfiSimpleFileSystemProtocolGuid ## SOMETIMES_CONSUMES @@ -131,7 +133,6 @@ [Pcd] gEfiMdeModulePkgTokenSpaceGuid.PcdProgressCodeOsLoaderLoad ## SOMETIME= S_CONSUMES gEfiMdeModulePkgTokenSpaceGuid.PcdProgressCodeOsLoaderStart ## SOMETIME= S_CONSUMES gEfiMdeModulePkgTokenSpaceGuid.PcdErrorCodeSetVariable ## CONSUMES - gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile ## CONSUMES gEfiMdeModulePkgTokenSpaceGuid.PcdTestKeyUsed ## = CONSUMES =20 # --=20 2.21.0.windows.1 --=20 Qian Yi