]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/PeiMemoryLib/MemLib.c
MdePkg BaseCpuLib: Convert X64/CpuFlushTlb.asm to NASM
[mirror_edk2.git] / MdePkg / Library / PeiMemoryLib / MemLib.c
index 3a27ab2e835f7a871214e27d76df0509e1102db0..4f1f01749c60dc51a9aef8d1224318a8fc3f0e04 100644 (file)
@@ -1,19 +1,31 @@
 /** @file\r
-  Base Memory Library.\r
+  Base Memory Library functions implementation bases on PeiServcie.\r
 \r
-  Copyright (c) 2006, Intel Corporation<BR>\r
-  All rights reserved. This program and the accompanying materials\r
+  Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>\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
+  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
-  Module Name:  MemLib.c\r
-\r
 **/\r
 \r
+#include "MemLibInternals.h"\r
+\r
+/**\r
+  Copies a source buffer to a destination buffer, and returns the destination buffer.\r
+\r
+  This function wraps the gPS->CopyMem ().\r
+  \r
+  @param  DestinationBuffer   The pointer to the destination buffer of the memory copy.\r
+  @param  SourceBuffer        The pointer to the source buffer of the memory copy.\r
+  @param  Length              The number of bytes to copy from SourceBuffer to DestinationBuffer.\r
+\r
+  @return DestinationBuffer.\r
+\r
+**/\r
 VOID *\r
 EFIAPI\r
 InternalMemCopyMem (\r
@@ -30,6 +42,18 @@ InternalMemCopyMem (
   return Destination;\r
 }\r
 \r
+/**\r
+  Fills a target buffer with a byte value, and returns the target buffer.\r
+\r
+  This function wraps the gPS->SetMem ().\r
+  \r
+  @param  Buffer    Memory to set.\r
+  @param  Size      The number of bytes to set.\r
+  @param  Value     Value of the set operation.\r
+\r
+  @return Buffer.\r
+\r
+**/\r
 VOID *\r
 EFIAPI\r
 InternalMemSetMem (\r