Synchronize MdePkg h files to Library/Base* c files.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6984 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
gikidy
2008-12-11 04:45:23 +00:00
parent 2fc60b7038
commit efb2311707
26 changed files with 277 additions and 186 deletions

View File

@@ -31,7 +31,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
If all Length bytes of the two buffers are identical, then 0 is returned. Otherwise, the
value returned is the first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
If Length > 0 and DestinationBuffer is NULL, then ASSERT().
If Length > 0 and SourceBuffer is NULL, then ASSERT().
If Length is greater than (MAX_ADDRESS - DestinationBuffer + 1), then ASSERT().
@@ -44,7 +44,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
@return 0 All Length bytes of the two buffers are identical.
@retval Non-zero The first mismatched byte in SourceBuffer subtracted from the first
mismatched byte in DestinationBuffer.
**/
INTN
EFIAPI

View File

@@ -22,9 +22,9 @@
/**
Copy Length bytes from Source to Destination.
@param Destination Target of copy
@param Source Place to copy from
@param Length Number of bytes to copy
@param DestinationBuffer Target of copy
@param SourceBuffer Place to copy from
@param Length Number of bytes to copy
@return Destination
@@ -32,8 +32,8 @@
VOID *
EFIAPI
InternalMemCopyMem (
OUT VOID *Destination,
IN CONST VOID *Source,
OUT VOID *DestinationBuffer,
IN CONST VOID *SourceBuffer,
IN UINTN Length
)
{
@@ -45,18 +45,18 @@ InternalMemCopyMem (
volatile UINT8 *Destination8;
CONST UINT8 *Source8;
if (Source > Destination) {
Destination8 = (UINT8*)Destination;
Source8 = (CONST UINT8*)Source;
if (SourceBuffer > DestinationBuffer) {
Destination8 = (UINT8*)DestinationBuffer;
Source8 = (CONST UINT8*)SourceBuffer;
while (Length-- != 0) {
*(Destination8++) = *(Source8++);
}
} else if (Source < Destination) {
Destination8 = (UINT8*)Destination + Length;
Source8 = (CONST UINT8*)Source + Length;
} else if (SourceBuffer < DestinationBuffer) {
Destination8 = (UINT8*)DestinationBuffer + Length;
Source8 = (CONST UINT8*)SourceBuffer + Length;
while (Length-- != 0) {
*(--Destination8) = *(--Source8);
}
}
return Destination;
return DestinationBuffer;
}

View File

@@ -23,9 +23,9 @@
/**
Set Buffer to Value for Size bytes.
@param Buffer Memory to set.
@param Length Number of bytes to set
@param Value Value of the set operation.
@param Buffer Memory to set.
@param Length Number of bytes to set
@param Value Value of the set operation.
@return Buffer