+\r
+/**\r
+ Checks whether the contents of a buffer are all zeros.\r
+\r
+ @param Buffer The pointer to the buffer to be checked.\r
+ @param Length The size of the buffer (in bytes) to be checked.\r
+\r
+ @retval TRUE Contents of the buffer are all zeros.\r
+ @retval FALSE Contents of the buffer are not all zeros.\r
+\r
+**/\r
+BOOLEAN\r
+EFIAPI\r
+InternalMemIsZeroBuffer (\r
+ IN CONST VOID *Buffer,\r
+ IN UINTN Length\r
+ )\r
+{\r
+ CONST UINT8 *BufferData;\r
+ UINTN Index;\r
+\r
+ BufferData = Buffer;\r
+ for (Index = 0; Index < Length; Index++) {\r
+ if (BufferData[Index] != 0) {\r
+ return FALSE;\r
+ }\r
+ }\r
+ return TRUE;\r
+}\r