From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Permerror (SPF Permanent Error: More than 10 MX records returned) identity=mailfrom; client-ip=134.134.136.31; helo=mga06.intel.com; envelope-from=jiewen.yao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id BBF202214E324 for ; Mon, 11 Dec 2017 05:23:19 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Dec 2017 05:27:57 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,391,1508828400"; d="scan'208";a="1814222" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga007.jf.intel.com with ESMTP; 11 Dec 2017 05:27:56 -0800 Received: from FMSMSX109.amr.corp.intel.com (10.18.116.9) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 11 Dec 2017 05:27:56 -0800 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by fmsmsx109.amr.corp.intel.com (10.18.116.9) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 11 Dec 2017 05:27:55 -0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.175]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.152]) with mapi id 14.03.0319.002; Mon, 11 Dec 2017 21:27:54 +0800 From: "Yao, Jiewen" To: "Zeng, Star" , "edk2-devel@lists.01.org" CC: Laszlo Ersek , "Dong, Eric" Thread-Topic: [edk2] [PATCH] MdeModulePkg: Rename SmmEndOfS3ResumeProtocolGuid to EndOfS3ResumeGuid Thread-Index: AQHTclsTz4fy2lGZb0WKHpFnOlf/AqM+In+g Date: Mon, 11 Dec 2017 13:27:53 +0000 Message-ID: <74D8A39837DF1E4DA445A8C0B3885C503AA42678@shsmsx102.ccr.corp.intel.com> References: <1512981336-3508-1-git-send-email-star.zeng@intel.com> In-Reply-To: <1512981336-3508-1-git-send-email-star.zeng@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiY2E5MTk4NTQtYWZiMi00YzIxLTg5YWUtZDkwNzZiNWZlYmMzIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjIuNS4xOCIsIlRydXN0ZWRMYWJlbEhhc2giOiJEVWF0M1RXQk5wR1NBV3N2NUVSS1ZTRVwvNllqYnZabHgzXC9sK1BIY3NDeTM2dmdJQWExWXdyOCtObzlzc2xyWjUifQ== x-ctpclassification: CTP_IC dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] MdeModulePkg: Rename SmmEndOfS3ResumeProtocolGuid to EndOfS3ResumeGuid X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Dec 2017 13:23:19 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Yes, I think EndOfS3ResumeGuid seems a better name. Reviewed-by: Jiewen.yao@intel.com Thank you Yao Jiewen > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Ze= ng, > Star > Sent: Monday, December 11, 2017 4:36 PM > To: edk2-devel@lists.01.org > Cc: Laszlo Ersek ; Yao, Jiewen ; > Dong, Eric ; Zeng, Star > Subject: [edk2] [PATCH] MdeModulePkg: Rename > SmmEndOfS3ResumeProtocolGuid to EndOfS3ResumeGuid >=20 > Rename SmmEndOfS3ResumeProtocolGuid to EndOfS3ResumeGuid as the GUID > may be used to install PPI in future to notify PEI phase code. >=20 > The references in UefiCpuPkg are also being updated. >=20 > Cc: Jiewen Yao > Cc: Eric Dong > Cc: Laszlo Ersek > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Star Zeng > --- > MdeModulePkg/Core/PiSmmCore/PiSmmCore.c | 10 > +++++----- > MdeModulePkg/Core/PiSmmCore/PiSmmCore.h | 2 > +- > MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf | 2 > +- > .../{Protocol/SmmEndOfS3Resume.h =3D> Guid/EndOfS3Resume.h} | 12 > ++++++------ > MdeModulePkg/MdeModulePkg.dec | > 6 +++--- > UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume.c | 9 > ++++----- > UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf | 6 > ++---- > 7 files changed, 22 insertions(+), 25 deletions(-) > rename MdeModulePkg/Include/{Protocol/SmmEndOfS3Resume.h =3D> > Guid/EndOfS3Resume.h} (67%) >=20 > diff --git a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.c > b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.c > index 4c1e3e719524..0b9c7958c75c 100644 > --- a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.c > +++ b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.c > @@ -81,7 +81,7 @@ SMM_CORE_SMI_HANDLERS mSmmCoreSmiHandlers[] > =3D { > { SmmExitBootServicesHandler, &gEfiEventExitBootServicesGuid, NUL= L, > FALSE }, > { SmmReadyToBootHandler, &gEfiEventReadyToBootGuid, > NULL, FALSE }, > { SmmEndOfDxeHandler, &gEfiEndOfDxeEventGroupGuid, > NULL, TRUE }, > - { SmmEndOfS3ResumeHandler, > &gEdkiiSmmEndOfS3ResumeProtocolGuid, NULL, FALSE }, > + { SmmEndOfS3ResumeHandler, &gEdkiiEndOfS3ResumeGuid, > NULL, FALSE }, > { NULL, NULL, > NULL, FALSE } > }; >=20 > @@ -384,7 +384,7 @@ SmmEndOfDxeHandler ( > } >=20 > /** > - Software SMI handler that is called when the EndOfS3Resume event is > trigged. > + Software SMI handler that is called when the EndOfS3Resume signal is > triggered. > This function installs the SMM EndOfS3Resume Protocol so SMM Drivers a= re > informed that > S3 resume has finished. >=20 > @@ -417,19 +417,19 @@ SmmEndOfS3ResumeHandler ( > SmmHandle =3D NULL; > Status =3D SmmInstallProtocolInterface ( > &SmmHandle, > - &gEdkiiSmmEndOfS3ResumeProtocolGuid, > + &gEdkiiEndOfS3ResumeGuid, > EFI_NATIVE_INTERFACE, > NULL > ); > ASSERT_EFI_ERROR (Status); >=20 > // > - // Uninstall the protocol here because the comsume just hook the > + // Uninstall the protocol here because the comsumer just hook the > // installation event. > // > Status =3D SmmUninstallProtocolInterface ( > SmmHandle, > - &gEdkiiSmmEndOfS3ResumeProtocolGuid, > + &gEdkiiEndOfS3ResumeGuid, > NULL > ); > ASSERT_EFI_ERROR (Status); > diff --git a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.h > b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.h > index cdc491c32429..2729a434d8f8 100644 > --- a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.h > +++ b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.h > @@ -32,7 +32,6 @@ > #include > #include > #include > -#include > #include >=20 > #include > @@ -41,6 +40,7 @@ > #include > #include > #include > +#include >=20 > #include > #include > diff --git a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf > b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf > index 01d706d0e312..de0037fe4a99 100644 > --- a/MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf > +++ b/MdeModulePkg/Core/PiSmmCore/PiSmmCore.inf > @@ -81,7 +81,6 @@ [Protocols] > gEdkiiSmmExitBootServicesProtocolGuid ## > SOMETIMES_PRODUCES > gEdkiiSmmLegacyBootProtocolGuid ## > SOMETIMES_PRODUCES > gEdkiiSmmReadyToBootProtocolGuid ## PRODUCES > - gEdkiiSmmEndOfS3ResumeProtocolGuid ## > SOMETIMES_PRODUCES >=20 > gEfiSmmSwDispatch2ProtocolGuid ## > SOMETIMES_CONSUMES > gEfiSmmSxDispatch2ProtocolGuid ## > SOMETIMES_CONSUMES > @@ -123,6 +122,7 @@ [Guids] > ## SOMETIMES_PRODUCES ## GUID # Install protocol > ## SOMETIMES_PRODUCES ## GUID # SmiHandlerRegister > gSmiHandlerProfileGuid > + gEdkiiEndOfS3ResumeGuid ## SOMETIMES_PRODUCES ## GUID # Install > protocol >=20 > [UserExtensions.TianoCore."ExtraFiles"] > PiSmmCoreExtra.uni > diff --git a/MdeModulePkg/Include/Protocol/SmmEndOfS3Resume.h > b/MdeModulePkg/Include/Guid/EndOfS3Resume.h > similarity index 67% > rename from MdeModulePkg/Include/Protocol/SmmEndOfS3Resume.h > rename to MdeModulePkg/Include/Guid/EndOfS3Resume.h > index 9716f6a22ac6..853aa1afbc17 100644 > --- a/MdeModulePkg/Include/Protocol/SmmEndOfS3Resume.h > +++ b/MdeModulePkg/Include/Guid/EndOfS3Resume.h > @@ -1,6 +1,6 @@ > /** @file > - This Protocol will be installed at the end of S3 resume phase in SMM > environment. > - It allows for smm drivers to hook this point and do the requried tasks= . > + This GUID will be installed at the end of S3 resume phase as protocol = in SMM > environment. > + It allows for SMM drivers to hook this point and do the required tasks= . >=20 > Copyright (c) 2017, Intel Corporation. All rights reserved.
> This program and the accompanying materials > @@ -13,14 +13,14 @@ >=20 > **/ >=20 > -#ifndef __SMM_END_OF_S3_RESUME_H__ > -#define __SMM_END_OF_S3_RESUME_H__ > +#ifndef __END_OF_S3_RESUME_H__ > +#define __END_OF_S3_RESUME_H__ >=20 > -#define EDKII_SMM_END_OF_S3_RESUME_PROTOCOL_GUID \ > +#define EDKII_END_OF_S3_RESUME_GUID \ > { \ > 0x96f5296d, 0x05f7, 0x4f3c, {0x84, 0x67, 0xe4, 0x56, 0x89, 0x0e, 0x0= c, > 0xb5 } \ > } >=20 > -extern EFI_GUID gEdkiiSmmEndOfS3ResumeProtocolGuid; > +extern EFI_GUID gEdkiiEndOfS3ResumeGuid; >=20 > #endif > diff --git a/MdeModulePkg/MdeModulePkg.dec > b/MdeModulePkg/MdeModulePkg.dec > index b3831a21ad08..8efad57766a0 100644 > --- a/MdeModulePkg/MdeModulePkg.dec > +++ b/MdeModulePkg/MdeModulePkg.dec > @@ -392,6 +392,9 @@ [Guids] > ## Include/Guid/PlatformHasAcpi.h > gEdkiiPlatformHasAcpiGuid =3D { 0xf0966b41, 0xc23f, 0x41b9, { 0x96, 0x= 04, > 0x0f, 0xf7, 0xe1, 0x11, 0x96, 0x5a } } >=20 > + ## Include/Guid/EndofS3Resume.h > + gEdkiiEndOfS3ResumeGuid =3D { 0x96f5296d, 0x05f7, 0x4f3c, {0x84, 0x67, > 0xe4, 0x56, 0x89, 0x0e, 0x0c, 0xb5 } } > + > [Ppis] > ## Include/Ppi/AtaController.h > gPeiAtaControllerPpiGuid =3D { 0xa45e60d1, 0xc719, 0x44aa, { 0xb= 0, > 0x7a, 0xaa, 0x77, 0x7f, 0x85, 0x90, 0x6d }} > @@ -556,9 +559,6 @@ [Protocols] > ## Include/Protocol/IoMmu.h > gEdkiiIoMmuProtocolGuid =3D { 0x4e939de9, 0xd948, 0x4b0f, { 0x88, 0xed= , > 0xe6, 0xe1, 0xce, 0x51, 0x7c, 0x1e } } >=20 > - ## Include/Protocol/SmmEndofS3Resume.h > - gEdkiiSmmEndOfS3ResumeProtocolGuid =3D { 0x96f5296d, 0x05f7, 0x4f3c, > {0x84, 0x67, 0xe4, 0x56, 0x89, 0x0e, 0x0c, 0xb5 } } > - > ## Include/Protocol/SmmMemoryAttribute.h > gEdkiiSmmMemoryAttributeProtocolGuid =3D { 0x69b792ea, 0x39ce, 0x402d, > { 0xa2, 0xa6, 0xf7, 0x21, 0xde, 0x35, 0x1d, 0xfe } } >=20 > diff --git a/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume.c > b/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume.c > index e0c2d366cd0d..b597ac7dc5ff 100644 > --- a/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume.c > +++ b/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume.c > @@ -23,6 +23,7 @@ > #include > #include > #include > +#include > #include > #include > #include > @@ -30,8 +31,6 @@ > #include > #include >=20 > -#include > - > #include > #include > #include > @@ -156,7 +155,7 @@ typedef union { >=20 > // > // Define two type of smm communicate headers. > -// One for 32 bits PEI + 64 bits DXE, the other for 32 bits PEI + 32 bi= ts DXE > case. > +// One for 32 bits PEI + 64 bits DXE, the other for 32 bits PEI + 32 bit= s DXE case. > // > typedef struct { > EFI_GUID HeaderGuid; > @@ -471,7 +470,7 @@ SignalEndOfS3Resume ( > // This buffer consumed in DXE phase, so base on DXE mode to prepare > communicate buffer. > // Detect whether DXE is 64 bits mode. > // if (sizeof(UINTN) =3D=3D sizeof(UINT64), PEI already 64 bits, assum= e DXE also > 64 bits. > - // or (FeaturePcdGet (PcdDxeIplSwitchToLongMode)), Dxe will switch to = 64 > bits. > + // or (FeaturePcdGet (PcdDxeIplSwitchToLongMode)), DXE will switch to = 64 > bits. > // > if ((sizeof(UINTN) =3D=3D sizeof(UINT64)) || (FeaturePcdGet > (PcdDxeIplSwitchToLongMode))) { > CommBuffer =3D &Header64; > @@ -482,7 +481,7 @@ SignalEndOfS3Resume ( > Header32.MessageLength =3D 0; > CommSize =3D OFFSET_OF (SMM_COMMUNICATE_HEADER_32, Data); > } > - CopyGuid (CommBuffer, &gEdkiiSmmEndOfS3ResumeProtocolGuid); > + CopyGuid (CommBuffer, &gEdkiiEndOfS3ResumeGuid); >=20 > Status =3D PeiServicesLocatePpi ( > &gEfiPeiSmmCommunicationPpiGuid, > diff --git a/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf > b/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf > index 943f114e6932..15fa2d15431c 100644 > --- a/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf > +++ b/UefiCpuPkg/Universal/Acpi/S3Resume2Pei/S3Resume2Pei.inf > @@ -5,7 +5,7 @@ > # This module will excute the boot script saved during last boot and aft= er that, > # control is passed to OS waking up handler. > # > -# Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved.
> +# Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
> # Copyright (c) 2017, AMD Incorporated. All rights reserved.
> # > # This program and the accompanying materials are > @@ -78,6 +78,7 @@ [Guids] > ## SOMETIMES_CONSUMES ## UNDEFINED # LockBox > gEfiAcpiVariableGuid > gEfiAcpiS3ContextGuid ## > SOMETIMES_CONSUMES ## UNDEFINED # LockBox > + gEdkiiEndOfS3ResumeGuid ## > SOMETIMES_CONSUMES ## UNDEFINED # Used to do smm communication >=20 > [Ppis] > gEfiPeiReadOnlyVariable2PpiGuid ## CONSUMES > @@ -87,9 +88,6 @@ [Ppis] > gEfiEndOfPeiSignalPpiGuid ## > SOMETIMES_PRODUCES > gEfiPeiSmmCommunicationPpiGuid ## > SOMETIMES_CONSUMES >=20 > -[Protocols] > - gEdkiiSmmEndOfS3ResumeProtocolGuid ## > SOMETIMES_CONSUMES > - > [FeaturePcd] > gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode > ## CONSUMES > gEfiMdeModulePkgTokenSpaceGuid.PcdFrameworkCompatibilitySupport > ## CONSUMES > -- > 2.7.0.windows.1 >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel