-/**\r
- Wrap original AllocatePool gBS call\r
- and ZeroMem gBS call into a single\r
- function in order to decrease code length\r
-\r
-\r
- @param Size The size to allocate\r
-\r
- @return Valid pointer to the allocated buffer\r
- @retval Null for failure\r
-\r
-**/\r
-VOID *\r
-EfiAllocateZeroPool (\r
- IN UINTN Size\r
- )\r
-{\r
- EFI_STATUS Status;\r
- VOID *Ptr;\r
- Status = gBS->AllocatePool (EfiBootServicesData, Size, &Ptr);\r
- if (EFI_ERROR (Status)) {\r
- Ptr = NULL;\r
- return Ptr;\r
- }\r
-\r
- ZeroMem (Ptr, Size);\r
- return Ptr;\r
-}\r
-\r