From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 BE55721AEB0B5 for ; Tue, 25 Jul 2017 23:59:54 -0700 (PDT) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga104.jf.intel.com with ESMTP; 26 Jul 2017 00:01:56 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,414,1496127600"; d="scan'208";a="1199426089" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by fmsmga002.fm.intel.com with ESMTP; 26 Jul 2017 00:01:51 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.319.2; Tue, 25 Jul 2017 23:59:44 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.146]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.116]) with mapi id 14.03.0319.002; Wed, 26 Jul 2017 14:59:42 +0800 From: "Yao, Jiewen" To: "Zeng, Star" , "edk2-devel@lists.01.org" Thread-Topic: [PATCH 3/3] UefiCpuPkg PiSmmCommunicationSmm: Deprecate SMM Communication ACPI Table Thread-Index: AQHTBdyJmI2Op5r2LkW9frdmnPPEl6JlrX/g Date: Wed, 26 Jul 2017 06:59:42 +0000 Message-ID: <74D8A39837DF1E4DA445A8C0B3885C503A97F487@shsmsx102.ccr.corp.intel.com> References: <1500558932-298208-1-git-send-email-star.zeng@intel.com> <1500558932-298208-4-git-send-email-star.zeng@intel.com> <0C09AFA07DD0434D9E2A0C6AEB0483103B8F5FC4@shsmsx102.ccr.corp.intel.com> In-Reply-To: <0C09AFA07DD0434D9E2A0C6AEB0483103B8F5FC4@shsmsx102.ccr.corp.intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 10.0.102.7 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH 3/3] UefiCpuPkg PiSmmCommunicationSmm: Deprecate SMM Communication ACPI Table 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: Wed, 26 Jul 2017 06:59:54 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Jiewen.yao@intel.com > -----Original Message----- > From: Zeng, Star > Sent: Thursday, July 20, 2017 9:56 PM > To: edk2-devel@lists.01.org > Cc: Zeng, Star ; Jiewen Yao ;= Fan, > Jeff > Subject: [PATCH 3/3] UefiCpuPkg PiSmmCommunicationSmm: Deprecate SMM > Communication ACPI Table >=20 > Follow UEFI 2.7 spec to deprecate SMM Communication ACPI Table, > PiSmmCommunicationSmm will not install SMM Communication ACPI Table > anymore. >=20 > Cc: Jiewen Yao > Cc: Jeff Fan > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Star Zeng > --- > .../PiSmmCommunication/PiSmmCommunicationSmm.c | 60 > +--------------------- > .../PiSmmCommunication/PiSmmCommunicationSmm.inf | 29 ++--------- > .../PiSmmCommunication/PiSmmCommunicationSmm.uni | 14 ++--- > .../PiSmmCommunicationSmmExtra.uni | 4 +- > 4 files changed, 13 insertions(+), 94 deletions(-) >=20 > diff --git a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.c > b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.c > index 077eacce88d1..2b395f38da64 100644 > --- a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.c > +++ b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.c > @@ -1,7 +1,7 @@ > /** @file > PiSmmCommunication SMM Driver. >=20 > -Copyright (c) 2010 - 2015, Intel Corporation. All rights reserved.
> +Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
> This program and the accompanying materials are licensed and made avail= able > under the terms and conditions of the BSD License which accompanies this > distribution. The full text of the license may be found at @@ -19,16 +19= ,11 @@ > WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR > IMPLIED. > #include #include > #include -#include #include > #include -#include > #include -#include > #include > -#include #include > -#include >=20 > #include "PiSmmCommunicationPrivate.h" >=20 > @@ -36,26 +31,6 @@ EFI_SMM_COMMUNICATION_CONTEXT > mSmmCommunicationContext =3D { > SMM_COMMUNICATION_SIGNATURE > }; >=20 > -EFI_SMM_COMMUNICATION_ACPI_TABLE mSmmCommunicationAcpiTable =3D > { > - { > - { > - EFI_ACPI_4_0_UEFI_ACPI_DATA_TABLE_SIGNATURE, > - sizeof (EFI_SMM_COMMUNICATION_ACPI_TABLE), > - 0x1, // Revision > - 0x0, // Checksum > - {0x0}, // OemId[6] > - 0x0, // OemTableId > - 0x0, // OemRevision > - 0x0, // CreatorId > - 0x0 // CreatorRevision > - }, > - {0x0}, // > Identifier > - OFFSET_OF (EFI_SMM_COMMUNICATION_ACPI_TABLE, SwSmiNumber) > // DataOffset > - }, > - 0x0, // > SwSmiNumber > - 0x0 // > BufferPtrAddress > -}; > - > /** > Set SMM communication context. > **/ > @@ -200,22 +175,8 @@ PiSmmCommunicationSmmEntryPoint ( > EFI_SMM_SW_DISPATCH2_PROTOCOL *SmmSwDispatch2; > EFI_SMM_SW_REGISTER_CONTEXT SmmSwDispatchContext; > EFI_HANDLE DispatchHandle; > - EFI_ACPI_TABLE_PROTOCOL *AcpiTableProtocol; > - UINTN TableKey; > - UINT64 OemTableId; > EFI_PHYSICAL_ADDRESS *BufferPtrAddress; >=20 > - CopyMem ( > - mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.OemId, > - PcdGetPtr (PcdAcpiDefaultOemId), > - sizeof (mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.OemId) > - ); > - OemTableId =3D PcdGet64 (PcdAcpiDefaultOemTableId); > - CopyMem > (&mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.OemTableId, > &OemTableId, sizeof (UINT64)); > - mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.OemRevision > =3D PcdGet32 (PcdAcpiDefaultOemRevision); > - mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.CreatorId > =3D PcdGet32 (PcdAcpiDefaultCreatorId); > - mSmmCommunicationAcpiTable.UefiAcpiDataTable.Header.CreatorRevision > =3D PcdGet32 (PcdAcpiDefaultCreatorRevision); > - > // > // Register software SMI handler > // > @@ -237,32 +198,15 @@ PiSmmCommunicationSmmEntryPoint ( >=20 > DEBUG ((EFI_D_INFO, "SmmCommunication SwSmi: %x\n", > (UINTN)SmmSwDispatchContext.SwSmiInputValue)); >=20 > - // > - // Set ACPI table > - // > - Status =3D gBS->LocateProtocol (&gEfiAcpiTableProtocolGuid, NULL, (VOI= D **) > &AcpiTableProtocol); > - ASSERT_EFI_ERROR (Status); > - > - mSmmCommunicationAcpiTable.SwSmiNumber =3D > (UINT32)SmmSwDispatchContext.SwSmiInputValue; > BufferPtrAddress =3D AllocateAcpiNvsMemoryBelow4G > (sizeof(EFI_PHYSICAL_ADDRESS)); > ASSERT (BufferPtrAddress !=3D NULL); > DEBUG ((EFI_D_INFO, "SmmCommunication BufferPtrAddress: 0x%016lx, > BufferPtr: 0x%016lx\n", (EFI_PHYSICAL_ADDRESS)(UINTN)BufferPtrAddress, > *BufferPtrAddress)); > - mSmmCommunicationAcpiTable.BufferPtrAddress =3D > (EFI_PHYSICAL_ADDRESS)(UINTN)BufferPtrAddress; > - CopyMem (&mSmmCommunicationAcpiTable.UefiAcpiDataTable.Identifier, > &gEfiSmmCommunicationProtocolGuid, > sizeof(gEfiSmmCommunicationProtocolGuid)); > - > - Status =3D AcpiTableProtocol->InstallAcpiTable ( > - AcpiTableProtocol, > - &mSmmCommunicationAcpiTable, > - sizeof(mSmmCommunicationAcpiTable), > - &TableKey > - ); > - ASSERT_EFI_ERROR (Status); >=20 > // > // Save context > // > mSmmCommunicationContext.SwSmiNumber =3D > (UINT32)SmmSwDispatchContext.SwSmiInputValue; > - mSmmCommunicationContext.BufferPtrAddress =3D > mSmmCommunicationAcpiTable.BufferPtrAddress; > + mSmmCommunicationContext.BufferPtrAddress =3D > + (EFI_PHYSICAL_ADDRESS)(UINTN)BufferPtrAddress; > SetCommunicationContext (); >=20 > return Status; > diff --git a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.inf > b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.inf > index 9b03837cf3f1..67799e9436cd 100644 > --- a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.inf > +++ b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.inf > @@ -1,12 +1,8 @@ > ## @file > -# PI SMM Communication SMM driver that installs the SMM Communication > ACPI Table. > +# PI SMM Communication SMM driver that saves SMM communication context > +# for use by SMM Communication PEIM in the S3 boot mode. > # > -# This SMM driver installs the SMM Communication ACPI Table defined in t= he > UEFI spec -# which provides a mechanism that can be used in the OS presen= t > environment by -# non-firmware agents for inter-mode communication with > SMM agents. It also saves -# SMM communication context for use by SMM > Communication PEIM in the S3 boot mode. > -# > -# Copyright (c) 2010 - 2015, Intel Corporation. All rights reserved.
> +# Copyright (c) 2010 - 2017, Intel Corporation. All rights > +reserved.
> # > # This program and the accompanying materials # are licensed and made > available under the terms and conditions of the BSD License @@ -49,34 +45= ,17 > @@ [LibraryClasses] > SmmServicesTableLib > BaseLib > BaseMemoryLib > - HobLib > DebugLib > SmmMemLib > - PcdLib > - > -[Guids] > - gEfiAcpi20TableGuid ## SOMETIMES_CONSUMES ## > SystemTable > - gEfiAcpi10TableGuid ## SOMETIMES_CONSUMES ## > SystemTable > - gEfiAcpiTableGuid ## SOMETIMES_CONSUMES ## > SystemTable >=20 > [Ppis] > gEfiPeiSmmCommunicationPpiGuid ## UNDEFINED # SMM > Configuration Table >=20 > [Protocols] > gEfiSmmSwDispatch2ProtocolGuid ## CONSUMES > - gEfiSmmCommunicationProtocolGuid ## UNDEFINED # SMM > Communication ACPI Table GUID > - gEfiAcpiTableProtocolGuid ## CONSUMES > - > -[Pcd] > - gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiDefaultOemId ## > CONSUMES > - gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiDefaultOemTableId ## > CONSUMES > - gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiDefaultOemRevision ## > CONSUMES > - gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiDefaultCreatorId ## > CONSUMES > - gEfiMdeModulePkgTokenSpaceGuid.PcdAcpiDefaultCreatorRevision ## > CONSUMES >=20 > [Depex] > - gEfiSmmSwDispatch2ProtocolGuid AND > - gEfiAcpiTableProtocolGuid > + gEfiSmmSwDispatch2ProtocolGuid >=20 > [UserExtensions.TianoCore."ExtraFiles"] > PiSmmCommunicationSmmExtra.uni > diff --git a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.uni > b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.uni > index 55df3905df08..9995b4ec7d9d 100644 > --- a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.uni > +++ b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmm.uni > @@ -1,12 +1,8 @@ > // /** @file > -// PI SMM Communication SMM driver that installs the SMM Communication > ACPI Table. > +// PI SMM Communication SMM driver that saves SMM communication context > +// for use by SMM Communication PEIM in the S3 boot mode. > // > -// This SMM driver installs the SMM Communication ACPI Table defined in = the > UEFI spec -// which provides a mechanism that can be used in the OS prese= nt > environment by -// non-firmware agents for inter-mode communication with > SMM agents. It also saves -// SMM communication context for use by SMM > Communication PEIM in the S3 boot mode. > -// > -// Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved. > +// Copyright (c) 2010 - 2017, Intel Corporation. All rights > +reserved.
> // > // This program and the accompanying materials // are licensed and made > available under the terms and conditions of the BSD License @@ -18,6 +14,= 6 @@ > // // **/ >=20 > -#string STR_MODULE_ABSTRACT #language en-US "PI SMM > Communication SMM driver that installs the SMM Communication ACPI Table" > +#string STR_MODULE_ABSTRACT #language en-US "PI SMM > Communication SMM driver that saves SMM communication context" >=20 > -#string STR_MODULE_DESCRIPTION #language en-US "This SMM > driver installs the SMM Communication ACPI Table defined in the UEFI > Specification, which provides a mechanism that can be used in the OS-pres= ent > environment by non-firmware agents for inter-mode communication with SMM > agents. It also saves an SMM communication context for use by SMM > Communication PEIM in the S3 boot mode." > +#string STR_MODULE_DESCRIPTION #language en-US "PI SMM > Communication SMM driver that saves SMM communication context for use by > SMM Communication PEIM in the S3 boot mode." > diff --git > a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmmExtra.uni > b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmmExtra.uni > index 34e7731fb5ae..bb7ce62dc589 100644 > --- a/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmmExtra.uni > +++ b/UefiCpuPkg/PiSmmCommunication/PiSmmCommunicationSmmExtra.uni > @@ -1,7 +1,7 @@ > // /** @file > // PiSmmCommunicationSmm Localized Strings and Content // -// Copyright= (c) > 2013 - 2014, Intel Corporation. All rights reserved.
> +// Copyright (c) 2013 - 2017, Intel Corporation. All rights > +reserved.
> // > // This program and the accompanying materials // are licensed and made > available under the terms and conditions of the BSD License @@ -15,4 +15,= 4 @@ >=20 > #string STR_PROPERTIES_MODULE_NAME > #language en-US > -"SMM Communication ACPI Table DXE Driver" > +"SMM Communication SMM Driver" > -- > 2.7.0.windows.1