From: "Wu, Hao A" <hao.a.wu@intel.com>
To: "devel@edk2.groups.io" <devel@edk2.groups.io>,
"kun.q@outlook.com" <kun.q@outlook.com>
Cc: "Wang, Jian J" <jian.j.wang@intel.com>,
"Dong, Eric" <eric.dong@intel.com>,
"Yao, Jiewen" <jiewen.yao@intel.com>
Subject: Re: [edk2-devel] [PATCH v1 05/15] MdeModulePkg: SmmLockBoxSmmLib: Support StandaloneMm for SmmLockBoxLib
Date: Tue, 22 Dec 2020 08:35:40 +0000 [thread overview]
Message-ID: <BN8PR11MB366673BAF070E869FE6353FECADF0@BN8PR11MB3666.namprd11.prod.outlook.com> (raw)
In-Reply-To: <MWHPR06MB3102FA7C30093B03FFAC67F1F3C30@MWHPR06MB3102.namprd06.prod.outlook.com>
A couple of minor inline comments below.
With them handled:
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
> -----Original Message-----
> From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Kun Qin
> Sent: Saturday, December 19, 2020 2:50 AM
> To: devel@edk2.groups.io
> Cc: Wang, Jian J <jian.j.wang@intel.com>; Wu, Hao A <hao.a.wu@intel.com>;
> Dong, Eric <eric.dong@intel.com>
> Subject: [edk2-devel] [PATCH v1 05/15] MdeModulePkg:
> SmmLockBoxSmmLib: Support StandaloneMm for SmmLockBoxLib
>
> This change added support of StandaloneMm for SmmLockBoxLib. It replaces
> gSmst with gMmst to support both traditional MM and standalone MM. The
> contructor and desctructor functions are abstracted to support different
> function prototype definitions.
>
> Cc: Jian J Wang <jian.j.wang@intel.com>
> Cc: Hao A Wu <hao.a.wu@intel.com>
> Cc: Eric Dong <eric.dong@intel.com>
>
> Signed-off-by: Kun Qin <kun.q@outlook.com>
> ---
> MdeModulePkg/Library/SmmLockBoxLib/{SmmLockBoxSmmLib.c =>
> SmmLockBoxMmLib.c} | 77 +++++++++-----------
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.c
> | 53 ++++++++++++++
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxTraditionalMmLib.c
> | 53 ++++++++++++++
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxLibPrivate.h
> | 27 +++++++
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> | 15 ++--
> MdeModulePkg/Library/SmmLockBoxLib/{SmmLockBoxSmmLib.inf =>
> SmmLockBoxStandaloneMmLib.inf} | 26 ++++---
> MdeModulePkg/MdeModulePkg.dsc | 2 +
> 7 files changed, 193 insertions(+), 60 deletions(-)
>
> diff --git a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxMmLib.c
> similarity index 89%
> rename from
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
> rename to MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxMmLib.c
> index 4cc0e8b78e5b..68fcf2a78ed6 100644
> --- a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.c
> +++ b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxMmLib.c
> @@ -6,16 +6,16 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
>
> **/
>
> -#include <PiSmm.h>
> -#include <Library/SmmServicesTableLib.h>
> +#include <PiMm.h>
> +#include <Library/MmServicesTableLib.h>
> #include <Library/BaseLib.h>
> #include <Library/BaseMemoryLib.h>
> #include <Library/LockBoxLib.h>
> #include <Library/DebugLib.h>
> #include <Guid/SmmLockBox.h>
> #include <Guid/EndOfS3Resume.h>
> -#include <Protocol/SmmReadyToLock.h>
> -#include <Protocol/SmmEndOfDxe.h>
> +#include <Protocol/MmReadyToLock.h>
> +#include <Protocol/MmEndOfDxe.h>
> #include <Protocol/SmmSxDispatch2.h>
>
> #include "SmmLockBoxLibPrivate.h"
> @@ -49,13 +49,13 @@ InternalGetSmmLockBoxContext (
> //
> // Check if gEfiSmmLockBoxCommunicationGuid is installed by someone
> //
> - for (Index = 0; Index < gSmst->NumberOfTableEntries; Index++) {
> - if (CompareGuid (&gSmst->SmmConfigurationTable[Index].VendorGuid,
> &gEfiSmmLockBoxCommunicationGuid)) {
> + for (Index = 0; Index < gMmst->NumberOfTableEntries; Index++) {
> + if (CompareGuid (&gMmst->MmConfigurationTable[Index].VendorGuid,
> + &gEfiSmmLockBoxCommunicationGuid)) {
> //
> // Found. That means some other library instance is already run.
> // No need to install again, just return.
> //
> - return (SMM_LOCK_BOX_CONTEXT *)gSmst-
> >SmmConfigurationTable[Index].VendorTable;
> + return (SMM_LOCK_BOX_CONTEXT
> + *)gMmst->MmConfigurationTable[Index].VendorTable;
> }
> }
>
> @@ -142,8 +142,8 @@ SmmLockBoxSmmEndOfDxeNotify (
> //
> // Locate SmmSxDispatch2 protocol.
> //
> - Status = gSmst->SmmLocateProtocol (
> - &gEfiSmmSxDispatch2ProtocolGuid,
> + Status = gMmst->MmLocateProtocol (
> + &gEfiMmSxDispatchProtocolGuid,
> NULL,
> (VOID **)&SxDispatch
> );
> @@ -191,29 +191,25 @@ SmmLockBoxEndOfS3ResumeNotify (
> Constructor for SmmLockBox library.
> This is used to set SmmLockBox context, which will be used in PEI phase in
> S3 boot path later.
>
> - @param[in] ImageHandle Image handle of this driver.
> - @param[in] SystemTable A Pointer to the EFI System Table.
> -
> @retval EFI_SUCEESS
> @return Others Some error occurs.
> **/
> EFI_STATUS
> EFIAPI
> -SmmLockBoxSmmConstructor (
> - IN EFI_HANDLE ImageHandle,
> - IN EFI_SYSTEM_TABLE *SystemTable
> +SmmLockBoxMmConstructor (
> + VOID
> )
Since function SmmLockBoxMmConstructor() now has become an library internal function.
Could you help to remove the 'EFIAPI' keyword for it?
> {
> EFI_STATUS Status;
> SMM_LOCK_BOX_CONTEXT *SmmLockBoxContext;
>
> - DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxSmmConstructor - Enter\n"));
> + DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxMmConstructor -
> + Enter\n"));
>
> //
> // Register SmmReadyToLock notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> - &gEfiSmmReadyToLockProtocolGuid,
> + Status = gMmst->MmRegisterProtocolNotify (
> + &gEfiMmReadyToLockProtocolGuid,
> SmmLockBoxSmmReadyToLockNotify,
> &mSmmLockBoxRegistrationSmmReadyToLock
> );
> @@ -222,8 +218,8 @@ SmmLockBoxSmmConstructor (
> //
> // Register SmmEndOfDxe notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> - &gEfiSmmEndOfDxeProtocolGuid,
> + Status = gMmst->MmRegisterProtocolNotify (
> + &gEfiMmEndOfDxeProtocolGuid,
> SmmLockBoxSmmEndOfDxeNotify,
> &mSmmLockBoxRegistrationSmmEndOfDxe
> );
> @@ -232,7 +228,7 @@ SmmLockBoxSmmConstructor (
> //
> // Register EndOfS3Resume notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> + Status = gMmst->MmRegisterProtocolNotify (
> &gEdkiiEndOfS3ResumeGuid,
> SmmLockBoxEndOfS3ResumeNotify,
> &mSmmLockBoxRegistrationEndOfS3Resume
> @@ -249,7 +245,7 @@ SmmLockBoxSmmConstructor (
> // No need to install again, just return.
> //
> DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib SmmLockBoxContext -
> already installed\n"));
> - DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxSmmConstructor - Exit\n"));
> + DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxMmConstructor -
> + Exit\n"));
> return EFI_SUCCESS;
> }
>
> @@ -263,8 +259,8 @@ SmmLockBoxSmmConstructor (
> }
> mSmmLockBoxContext.LockBoxDataAddress =
> (EFI_PHYSICAL_ADDRESS)(UINTN)&mLockBoxQueue;
>
> - Status = gSmst->SmmInstallConfigurationTable (
> - gSmst,
> + Status = gMmst->MmInstallConfigurationTable (
> + gMmst,
> &gEfiSmmLockBoxCommunicationGuid,
> &mSmmLockBoxContext,
> sizeof(mSmmLockBoxContext) @@ -274,7 +270,7 @@
> SmmLockBoxSmmConstructor (
>
> DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib SmmLockBoxContext -
> %x\n", (UINTN)&mSmmLockBoxContext));
> DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib LockBoxDataAddress -
> %x\n", (UINTN)&mLockBoxQueue));
> - DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxSmmConstructor - Exit\n"));
> + DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxMmConstructor -
> + Exit\n"));
>
> return Status;
> }
> @@ -292,18 +288,17 @@ SmmLockBoxSmmConstructor ( **/ EFI_STATUS
> EFIAPI -SmmLockBoxSmmDestructor (
> - IN EFI_HANDLE ImageHandle,
> - IN EFI_SYSTEM_TABLE *SystemTable
> +SmmLockBoxMmDestructor (
> + VOID
> )
Since function SmmLockBoxMmDestructor() now has become an library internal function.
Could you help to remove the 'EFIAPI' keyword for it?
Best Regards,
Hao Wu
> {
> EFI_STATUS Status;
>
> - DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib
> SmmLockBoxSmmDestructor in %a module\n", gEfiCallerBaseName));
> + DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib SmmLockBoxMmDestructor
> in %a
> + module\n", gEfiCallerBaseName));
>
> if (mSmmConfigurationTableInstalled) {
> - Status = gSmst->SmmInstallConfigurationTable (
> - gSmst,
> + Status = gMmst->MmInstallConfigurationTable (
> + gMmst,
> &gEfiSmmLockBoxCommunicationGuid,
> NULL,
> 0
> @@ -316,8 +311,8 @@ SmmLockBoxSmmDestructor (
> //
> // Unregister SmmReadyToLock notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> - &gEfiSmmReadyToLockProtocolGuid,
> + Status = gMmst->MmRegisterProtocolNotify (
> + &gEfiMmReadyToLockProtocolGuid,
> NULL,
> &mSmmLockBoxRegistrationSmmReadyToLock
> );
> @@ -327,8 +322,8 @@ SmmLockBoxSmmDestructor (
> //
> // Unregister SmmEndOfDxe notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> - &gEfiSmmEndOfDxeProtocolGuid,
> + Status = gMmst->MmRegisterProtocolNotify (
> + &gEfiMmEndOfDxeProtocolGuid,
> NULL,
> &mSmmLockBoxRegistrationSmmEndOfDxe
> );
> @@ -338,7 +333,7 @@ SmmLockBoxSmmDestructor (
> //
> // Unregister EndOfS3Resume notification.
> //
> - Status = gSmst->SmmRegisterProtocolNotify (
> + Status = gMmst->MmRegisterProtocolNotify (
> &gEdkiiEndOfS3ResumeGuid,
> NULL,
> &mSmmLockBoxRegistrationEndOfS3Resume
> @@ -453,7 +448,7 @@ SaveLockBox (
> //
> // Allocate SMRAM buffer
> //
> - Status = gSmst->SmmAllocatePages (
> + Status = gMmst->MmAllocatePages (
> AllocateAnyPages,
> EfiRuntimeServicesData,
> EFI_SIZE_TO_PAGES (Length), @@ -468,14 +463,14 @@
> SaveLockBox (
> //
> // Allocate LockBox
> //
> - Status = gSmst->SmmAllocatePool (
> + Status = gMmst->MmAllocatePool (
> EfiRuntimeServicesData,
> sizeof(*LockBox),
> (VOID **)&LockBox
> );
> ASSERT_EFI_ERROR (Status);
> if (EFI_ERROR (Status)) {
> - gSmst->SmmFreePages (SmramBuffer, EFI_SIZE_TO_PAGES (Length));
> + gMmst->MmFreePages (SmramBuffer, EFI_SIZE_TO_PAGES (Length));
> DEBUG ((DEBUG_INFO, "SmmLockBoxSmmLib SaveLockBox - Exit (%r)\n",
> EFI_OUT_OF_RESOURCES));
> return EFI_OUT_OF_RESOURCES;
> }
> @@ -662,7 +657,7 @@ UpdateLockBox (
> DEBUG_INFO,
> "SmmLockBoxSmmLib UpdateLockBox - Allocate new buffer to
> enlarge.\n"
> ));
> - Status = gSmst->SmmAllocatePages (
> + Status = gMmst->MmAllocatePages (
> AllocateAnyPages,
> EfiRuntimeServicesData,
> EFI_SIZE_TO_PAGES (Offset + Length), @@ -679,7 +674,7 @@
> UpdateLockBox (
> //
> CopyMem ((VOID *)(UINTN)SmramBuffer, (VOID *)(UINTN)LockBox-
> >SmramBuffer, (UINTN)LockBox->Length);
> ZeroMem ((VOID *)(UINTN)LockBox->SmramBuffer, (UINTN)LockBox-
> >Length);
> - gSmst->SmmFreePages (LockBox->SmramBuffer, EFI_SIZE_TO_PAGES
> ((UINTN)LockBox->Length));
> + gMmst->MmFreePages (LockBox->SmramBuffer, EFI_SIZE_TO_PAGES
> + ((UINTN)LockBox->Length));
>
> LockBox->SmramBuffer = SmramBuffer;
> }
> diff --git
> a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.
> c
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.
> c
> new file mode 100644
> index 000000000000..722121da430b
> --- /dev/null
> +++
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.
> c
> @@ -0,0 +1,53 @@
> +/** @file
> +
> +Copyright (c) 2010 - 2019, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.
> +
> +SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include <PiMm.h>
> +
> +#include "SmmLockBoxLibPrivate.h"
> +
> +/**
> + Constructor for SmmLockBox library.
> + This is used to set SmmLockBox context, which will be used in PEI phase in
> S3 boot path later.
> +
> + @param[in] ImageHandle Image handle of this driver.
> + @param[in] SystemTable A Pointer to the EFI System Table.
> +
> + @retval EFI_SUCEESS
> + @return Others Some error occurs.
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxStandaloneMmConstructor (
> + IN EFI_HANDLE ImageHandle,
> + IN EFI_MM_SYSTEM_TABLE *SystemTable
> + )
> +{
> + return SmmLockBoxMmConstructor ();
> +}
> +
> +/**
> + Destructor for SmmLockBox library.
> + This is used to uninstall SmmLockBoxCommunication configuration table
> + if it has been installed in Constructor.
> +
> + @param[in] ImageHandle Image handle of this driver.
> + @param[in] SystemTable A Pointer to the EFI System Table.
> +
> + @retval EFI_SUCEESS The destructor always returns EFI_SUCCESS.
> +
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxStandaloneMmDestructor (
> + IN EFI_HANDLE ImageHandle,
> + IN EFI_MM_SYSTEM_TABLE *SystemTable
> + )
> +{
> + return SmmLockBoxMmDestructor ();
> +}
> diff --git
> a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxTraditionalMmLib.c
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxTraditionalMmLib.c
> new file mode 100644
> index 000000000000..a748abb16c54
> --- /dev/null
> +++
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxTraditionalMmLib.c
> @@ -0,0 +1,53 @@
> +/** @file
> +
> +Copyright (c) 2010 - 2019, Intel Corporation. All rights reserved.<BR>
> +Copyright (c) Microsoft Corporation.
> +
> +SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include <PiSmm.h>
> +
> +#include "SmmLockBoxLibPrivate.h"
> +
> +/**
> + Constructor for SmmLockBox library.
> + This is used to set SmmLockBox context, which will be used in PEI phase in
> S3 boot path later.
> +
> + @param[in] ImageHandle Image handle of this driver.
> + @param[in] SystemTable A Pointer to the EFI System Table.
> +
> + @retval EFI_SUCEESS
> + @return Others Some error occurs.
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxTraditionalConstructor (
> + IN EFI_HANDLE ImageHandle,
> + IN EFI_SYSTEM_TABLE *SystemTable
> + )
> +{
> + return SmmLockBoxMmConstructor ();
> +}
> +
> +/**
> + Destructor for SmmLockBox library.
> + This is used to uninstall SmmLockBoxCommunication configuration table
> + if it has been installed in Constructor.
> +
> + @param[in] ImageHandle Image handle of this driver.
> + @param[in] SystemTable A Pointer to the EFI System Table.
> +
> + @retval EFI_SUCEESS The destructor always returns EFI_SUCCESS.
> +
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxTraditionalDestructor (
> + IN EFI_HANDLE ImageHandle,
> + IN EFI_SYSTEM_TABLE *SystemTable
> + )
> +{
> + return SmmLockBoxMmDestructor ();
> +}
> diff --git
> a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxLibPrivate.h
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxLibPrivate.h
> index 35311cb85d69..f729c6cceeea 100644
> --- a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxLibPrivate.h
> +++ b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxLibPrivate.h
> @@ -43,5 +43,32 @@ typedef struct {
>
> #pragma pack()
>
> +/**
> + Constructor for SmmLockBox library.
> + This is used to set SmmLockBox context, which will be used in PEI phase in
> S3 boot path later.
> +
> + @retval EFI_SUCEESS
> + @return Others Some error occurs.
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxMmConstructor (
> + VOID
> + );
> +
> +/**
> + Destructor for SmmLockBox library.
> + This is used to uninstall SmmLockBoxCommunication configuration table
> + if it has been installed in Constructor.
> +
> + @retval EFI_SUCEESS The destructor always returns EFI_SUCCESS.
> +
> +**/
> +EFI_STATUS
> +EFIAPI
> +SmmLockBoxMmDestructor (
> + VOID
> + );
> +
> #endif
>
> diff --git a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> index 2b6cc983b988..44f7b63c5d20 100644
> --- a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> +++ b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> @@ -15,8 +15,8 @@ [Defines]
> MODULE_TYPE = DXE_SMM_DRIVER
> VERSION_STRING = 1.0
> LIBRARY_CLASS = LockBoxLib|DXE_SMM_DRIVER
> - CONSTRUCTOR = SmmLockBoxSmmConstructor
> - DESTRUCTOR = SmmLockBoxSmmDestructor
> + CONSTRUCTOR = SmmLockBoxTraditionalConstructor
> + DESTRUCTOR = SmmLockBoxTraditionalDestructor
>
> #
> # The following information is for reference only and not required by the
> build tools.
> @@ -25,7 +25,8 @@ [Defines]
> #
>
> [Sources]
> - SmmLockBoxSmmLib.c
> + SmmLockBoxTraditionalMmLib.c
> + SmmLockBoxMmLib.c
> SmmLockBoxLibPrivate.h
>
> [Packages]
> @@ -33,14 +34,14 @@ [Packages]
> MdeModulePkg/MdeModulePkg.dec
>
> [LibraryClasses]
> - SmmServicesTableLib
> + MmServicesTableLib
> BaseLib
> DebugLib
>
> [Protocols]
> - gEfiSmmReadyToLockProtocolGuid ## NOTIFY
> - gEfiSmmEndOfDxeProtocolGuid ## NOTIFY
> - gEfiSmmSxDispatch2ProtocolGuid ## NOTIFY
> + gEfiMmReadyToLockProtocolGuid ## NOTIFY
> + gEfiMmEndOfDxeProtocolGuid ## NOTIFY
> + gEfiMmSxDispatchProtocolGuid ## NOTIFY
>
> [Guids]
> ## SOMETIMES_CONSUMES ## UNDEFINED # SmmSystemTable
> diff --git a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.i
> nf
> similarity index 52%
> copy from MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> copy to
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.inf
> index 2b6cc983b988..d46dfb3f9aa8 100644
> --- a/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> +++
> b/MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.i
> nf
> @@ -2,6 +2,7 @@
> # SMM LockBox library instance.
> #
> # Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.<BR>
> +# Copyright (c) Microsoft Corporation.
> #
> # SPDX-License-Identifier: BSD-2-Clause-Patent # @@ -9,14 +10,14 @@
>
> [Defines]
> INF_VERSION = 0x00010005
> - BASE_NAME = SmmLockBoxSmmLib
> - MODULE_UNI_FILE = SmmLockBoxSmmLib.uni
> - FILE_GUID = E04894D6-290D-4171-A362-0ACFD939F3C8
> - MODULE_TYPE = DXE_SMM_DRIVER
> + BASE_NAME = SmmLockBoxStandaloneMmLib
> + FILE_GUID = 3C05978B-30CA-4544-9C5A-AB99265EFC31
> + MODULE_TYPE = MM_STANDALONE
> VERSION_STRING = 1.0
> - LIBRARY_CLASS = LockBoxLib|DXE_SMM_DRIVER
> - CONSTRUCTOR = SmmLockBoxSmmConstructor
> - DESTRUCTOR = SmmLockBoxSmmDestructor
> + PI_SPECIFICATION_VERSION = 0x00010032
> + LIBRARY_CLASS = LockBoxLib|MM_STANDALONE
> + CONSTRUCTOR = SmmLockBoxStandaloneMmConstructor
> + DESTRUCTOR = SmmLockBoxStandaloneMmDestructor
>
> #
> # The following information is for reference only and not required by the
> build tools.
> @@ -25,7 +26,8 @@ [Defines]
> #
>
> [Sources]
> - SmmLockBoxSmmLib.c
> + SmmLockBoxStandaloneMmLib.c
> + SmmLockBoxMmLib.c
> SmmLockBoxLibPrivate.h
>
> [Packages]
> @@ -33,14 +35,14 @@ [Packages]
> MdeModulePkg/MdeModulePkg.dec
>
> [LibraryClasses]
> - SmmServicesTableLib
> + MmServicesTableLib
> BaseLib
> DebugLib
>
> [Protocols]
> - gEfiSmmReadyToLockProtocolGuid ## NOTIFY
> - gEfiSmmEndOfDxeProtocolGuid ## NOTIFY
> - gEfiSmmSxDispatch2ProtocolGuid ## NOTIFY
> + gEfiMmReadyToLockProtocolGuid ## NOTIFY
> + gEfiMmEndOfDxeProtocolGuid ## NOTIFY
> + gEfiMmSxDispatchProtocolGuid ## NOTIFY
>
> [Guids]
> ## SOMETIMES_CONSUMES ## UNDEFINED # SmmSystemTable
> diff --git a/MdeModulePkg/MdeModulePkg.dsc
> b/MdeModulePkg/MdeModulePkg.dsc index 90165ca443bf..cd91a70b4fdd
> 100644
> --- a/MdeModulePkg/MdeModulePkg.dsc
> +++ b/MdeModulePkg/MdeModulePkg.dsc
> @@ -167,6 +167,7 @@ [LibraryClasses.common.MM_STANDALONE]
>
> MemoryAllocationLib|MdeModulePkg/Library/BaseMemoryAllocationLibNul
> l/BaseMemoryAllocationLibNull.inf
>
> StandaloneMmDriverEntryPoint|MdePkg/Library/StandaloneMmDriverEntry
> Point/StandaloneMmDriverEntryPoint.inf
>
> MmServicesTableLib|MdePkg/Library/StandaloneMmServicesTableLib/Stan
> daloneMmServicesTableLib.inf
> +
> +
> LockBoxLib|MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandalo
> neMmLi
> + b.inf
>
> [LibraryClasses.ARM, LibraryClasses.AARCH64]
> ArmLib|ArmPkg/Library/ArmLib/ArmBaseLib.inf
> @@ -483,6 +484,7 @@ [Components.IA32, Components.X64]
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxPeiLib.inf
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxDxeLib.inf
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxSmmLib.inf
> +
> MdeModulePkg/Library/SmmLockBoxLib/SmmLockBoxStandaloneMmLib.inf
>
> MdeModulePkg/Library/SmmCorePlatformHookLibNull/SmmCorePlatformH
> ookLibNull.inf
>
> MdeModulePkg/Library/SmmSmiHandlerProfileLib/SmmSmiHandlerProfileLi
> b.inf
>
> MdeModulePkg/Library/LzmaCustomDecompressLib/LzmaArchCustomDeco
> mpressLib.inf
> --
> 2.28.0.windows.1
>
>
>
>
>
next prev parent reply other threads:[~2020-12-22 8:35 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20201218185011.1366-1-kun.q@outlook.com>
2020-12-18 18:49 ` [PATCH v1 01/15] StandaloneMmPkg: StandaloneMmCoreEntryPoint: Extends support for X64 Kun Qin
2020-12-28 0:11 ` [edk2-devel] " Yao, Jiewen
2020-12-18 18:49 ` [PATCH v1 02/15] StandaloneMmPkg: StandaloneMmCoreHobLib: Extend support for x64 Mm Core Kun Qin
2020-12-28 0:12 ` Yao, Jiewen
2021-03-24 20:33 ` [edk2-devel] " Dawn
2020-12-18 18:49 ` [PATCH v1 03/15] StandaloneMmPkg: StandaloneMmCoreMemoryAllocationLib: Fix compiler warning Kun Qin
2020-12-28 0:14 ` Yao, Jiewen
2020-12-28 4:07 ` Kun Qin
2020-12-18 18:50 ` [PATCH v1 04/15] StandaloneMmPkg: StandaloneMmMemLib: Extends support for X64 architecture Kun Qin
2020-12-28 0:18 ` Yao, Jiewen
2020-12-28 4:15 ` Kun Qin
2020-12-28 6:24 ` Yao, Jiewen
2020-12-28 6:36 ` Kun Qin
2020-12-28 6:37 ` [edk2-devel] " Yao, Jiewen
2020-12-18 18:50 ` [PATCH v1 05/15] MdeModulePkg: SmmLockBoxSmmLib: Support StandaloneMm for SmmLockBoxLib Kun Qin
2020-12-22 8:35 ` Wu, Hao A [this message]
2020-12-18 18:50 ` [PATCH v1 06/15] MdeModulePkg: SmmReportStatusCodeLib: ReportStatusCodeLib in StandaloneMm Kun Qin
2020-12-22 8:35 ` [edk2-devel] " Wu, Hao A
2020-12-22 19:15 ` Kun Qin
2020-12-23 6:09 ` Wu, Hao A
2020-12-24 1:53 ` 回复: " gaoliming
2020-12-24 9:11 ` Kun Qin
2020-12-29 1:23 ` 回复: " gaoliming
2020-12-29 1:31 ` Kun Qin
2020-12-18 18:50 ` [PATCH v1 07/15] MdeModulePkg: FirmwarePerformanceDataTable: Added StandaloneMm support Kun Qin
2020-12-22 8:36 ` Wu, Hao A
2020-12-22 20:06 ` [edk2-devel] " Kun Qin
2020-12-18 18:50 ` [PATCH v1 08/15] MdeModulePkg: ReportStatusCodeRouter: Support StandaloneMm RSC Router Kun Qin
2020-12-22 8:42 ` Wu, Hao A
2020-12-18 18:50 ` [PATCH v1 09/15] MdePkg: UefiDevicePathLib: Support UefiDevicePathLib under StandaloneMm Kun Qin
2021-01-04 18:32 ` [edk2-devel] " Kun Qin
2021-01-05 13:25 ` 回复: " gaoliming
2020-12-18 18:50 ` [PATCH v1 10/15] PcAtChipsetPkg: AcpiTimerLib: Added StandaloneMm instance of AcpiTimerLib Kun Qin
2021-01-04 18:30 ` [edk2-devel] " Kun Qin
2020-12-18 18:50 ` [PATCH v1 11/15] SecurityPkg: Tcg2PhysicalPresenceLib: Introduce StandaloneMm instance Kun Qin
2020-12-28 0:08 ` Yao, Jiewen
2020-12-18 18:50 ` [PATCH v1 12/15] SecurityPkg: Tcg2PpVendorLibNull: Added support for MM_STANDALONE type Kun Qin
2020-12-28 0:08 ` Yao, Jiewen
2020-12-18 18:50 ` [PATCH v1 13/15] SecurityPkg: Tpm2DeviceLibDTpm: Introduce StandaloneMm instance Kun Qin
2020-12-28 0:08 ` Yao, Jiewen
2020-12-18 18:50 ` [PATCH v1 14/15] UefiCpuPkg: CpuIo2Smm: Support of CpuIo driver under StandaloneMm Kun Qin
2021-01-04 18:31 ` [edk2-devel] " Kun Qin
2020-12-18 18:50 ` [PATCH v1 15/15] UefiCpuPkg: SmmCpuExceptionHandlerLib: Added StandaloneMm module support Kun Qin
2021-01-04 18:30 ` [edk2-devel] " Kun Qin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=BN8PR11MB366673BAF070E869FE6353FECADF0@BN8PR11MB3666.namprd11.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox