]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Move SmmCoreSmmServicesTableLib from MdePkg to MdeModulePkg.
authorjyao1 <jyao1@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 5 Mar 2010 04:05:28 +0000 (04:05 +0000)
committerjyao1 <jyao1@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 5 Mar 2010 04:05:28 +0000 (04:05 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10204 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.c [new file with mode: 0644]
MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.inf [new file with mode: 0644]

diff --git a/MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.c b/MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.c
new file mode 100644 (file)
index 0000000..2ce151e
--- /dev/null
@@ -0,0 +1,40 @@
+/** @file\r
+  SMM Core SMM Services Table Library.\r
+\r
+  Copyright (c) 2010, Intel Corporation<BR>\r
+  All rights reserved. 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
+#include <PiSmm.h>\r
+#include <Library/SmmServicesTableLib.h>\r
+#include <Library/DebugLib.h>\r
+\r
+EFI_SMM_SYSTEM_TABLE2         *gSmst = NULL;\r
+extern EFI_SMM_SYSTEM_TABLE2  gSmmCoreSmst;\r
+\r
+/**\r
+  The constructor function caches the pointer of SMM Services Table.\r
+\r
+  @param  ImageHandle   The firmware allocated handle for the EFI image.\r
+  @param  SystemTable   A pointer to the EFI System Table.\r
+\r
+  @retval EFI_SUCCESS   The constructor always returns EFI_SUCCESS.\r
+\r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+SmmCoreSmmServicesTableLibConstructor (\r
+  IN EFI_HANDLE        ImageHandle,\r
+  IN EFI_SYSTEM_TABLE  *SystemTable\r
+  )\r
+{\r
+  gSmst = &gSmmCoreSmst;\r
+  return EFI_SUCCESS;\r
+}\r
diff --git a/MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.inf b/MdeModulePkg/Library/PiSmmCoreSmmServicesTableLib/PiSmmCoreSmmServicesTableLib.inf
new file mode 100644 (file)
index 0000000..df807d3
--- /dev/null
@@ -0,0 +1,37 @@
+## @file\r
+# SMM Core SMM Services Table Library.\r
+#\r
+# Copyright (c) 2010, Intel Corporation.\r
+#\r
+#  All rights reserved. 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
+#  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
+\r
+[Defines]\r
+  INF_VERSION                    = 0x00010005\r
+  BASE_NAME                      = PiSmmCoreSmmServicesTableLib\r
+  FILE_GUID                      = C427146A-2EF2-4af9-A85A-E09EA65EE47D\r
+  MODULE_TYPE                    = SMM_CORE\r
+  VERSION_STRING                 = 1.0\r
+  LIBRARY_CLASS                  = SmmServicesTableLib|SMM_CORE\r
+  PI_SPECIFICATION_VERSION       = 0x0001000A\r
+  CONSTRUCTOR                    = SmmCoreSmmServicesTableLibConstructor\r
+\r
+#\r
+#  VALID_ARCHITECTURES           = IA32 X64\r
+#\r
+\r
+[Sources]\r
+  PiSmmCoreSmmServicesTableLib.c\r
+\r
+[Packages]\r
+  MdePkg/MdePkg.dec\r
+\r
+[LibraryClasses]\r
+  DebugLib\r