MdePkg/Include: add MmServicesTableLib header file
authorJagadeesh Ujja <jagadeesh.ujja@arm.com>
Thu, 3 Jan 2019 18:28:20 +0000 (19:28 +0100)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Mon, 14 Jan 2019 08:16:39 +0000 (09:16 +0100)
SMM has been rebranded as MM, and can be implemented in traditional
mode or standalone mode, using the same prototype for the services
table. Expose this table via MmServicesTableLib, permitting the
respective implementations to expose a traditional or standalone
version.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Jagadeesh Ujja <jagadeesh.ujja@arm.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
MdePkg/Include/Library/MmServicesTableLib.h [new file with mode: 0644]
MdePkg/MdePkg.dec

diff --git a/MdePkg/Include/Library/MmServicesTableLib.h b/MdePkg/Include/Library/MmServicesTableLib.h
new file mode 100644 (file)
index 0000000..56a03e0
--- /dev/null
@@ -0,0 +1,25 @@
+/** @file\r
+  Provides a service to retrieve a pointer to the Standalone MM Services Table.\r
+  Only available to MM_STANDALONE, SMM/DXE Combined and SMM module types.\r
+\r
+Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2016 - 2018, ARM Limited. All rights reserved.<BR>\r
+\r
+This program and the accompanying materials\r
+are licensed and made available under the terms and conditions of the BSD License\r
+which accompanies this distribution.  The full text of the license may be found at\r
+http://opensource.org/licenses/bsd-license.php\r
+\r
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
+**/\r
+\r
+#ifndef __MM_SERVICES_TABLE_LIB_H__\r
+#define __MM_SERVICES_TABLE_LIB_H__\r
+\r
+#include <PiMm.h>\r
+\r
+extern EFI_MM_SYSTEM_TABLE         *gMmst;\r
+\r
+#endif\r
index 712bd46..a7383b6 100644 (file)
   ##\r
   SafeIntLib|Include/Library/SafeIntLib.h\r
 \r
+  ## @libraryclass Provides a service to retrieve a pointer to the Standalone MM Services Table.\r
+  #                Only available to MM_STANDALONE, SMM/DXE Combined and SMM module types.\r
+  MmServicesTableLib|Include/Library/MmServicesTableLib.h\r
+\r
 [LibraryClasses.IA32, LibraryClasses.X64]\r
   ##  @libraryclass  Abstracts both S/W SMI generation and detection.\r
   ##\r