BaseMemoryLibSse2\r
BaseMemoryLibRepStr\r
PeiMemoryLib\r
- UefiMemoryLib\r
+ DxeMemoryLib\r
\r
**/\r
\r
GUID in the target buffer is returned. If no match is found, then NULL is returned.\r
If Length is 0, then NULL is returned.\r
If Length > 0 and Buffer is NULL, then ASSERT().\r
- If Buffer is not aligned on a 64-bit boundary, then ASSERT().\r
- If Length is greater than (MAX_ADDRESS \96 Buffer + 1), then ASSERT(). \r
+ If Buffer is not aligned on a 32-bit boundary, then ASSERT().\r
+ If Length is not aligned on a 128-bit boundary, then ASSERT().\r
+ If Length is greater than (MAX_ADDRESS ? Buffer + 1), then ASSERT(). \r
\r
@param Buffer Pointer to the target buffer to scan.\r
@param Length Number of bytes in Buffer to scan.\r
{\r
CONST GUID *GuidPtr;\r
\r
- ASSERT (Buffer != NULL);\r
- //\r
- // Make sure Buffer is aligned on a 64-bit boundary.\r
- //\r
- ASSERT (((UINTN) Buffer & 7) == 0);\r
-\r
+ ASSERT (((UINTN)Buffer & (sizeof (Guid->Data1) - 1)) == 0);\r
ASSERT (Length <= (MAX_ADDRESS - (UINTN)Buffer + 1));\r
+ ASSERT ((Length & (sizeof (*GuidPtr) - 1)) == 0);\r
\r
GuidPtr = (GUID*)Buffer;\r
- Buffer = GuidPtr + Length / sizeof (*GuidPtr);\r
+ Buffer = GuidPtr + Length / sizeof (*GuidPtr);\r
while (GuidPtr < (CONST GUID*)Buffer) {\r
if (CompareGuid (GuidPtr, Guid)) {\r
return (VOID*)GuidPtr;\r