]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c
MdeModulePkg DxeIplPeim: Add ASSERTs for unexpected AllocatePages failure
[mirror_edk2.git] / MdeModulePkg / Core / DxeIplPeim / X64 / VirtualMemory.c
index ab1e91462ea7a563fdf15bdb3bdc586421369b0f..790f6ab6b87fcf3b343ffbc09b14862c5395375c 100644 (file)
@@ -15,7 +15,7 @@
     2) IA-32 Intel(R) Architecture Software Developer's Manual Volume 2:Instruction Set Reference, Intel\r
     3) IA-32 Intel(R) Architecture Software Developer's Manual Volume 3:System Programmer's Guide, Intel\r
 \r
-Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2016, 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
@@ -67,6 +67,7 @@ Split2MPageTo4K (
   PAGE_TABLE_4K_ENTRY                   *PageTableEntry;\r
 \r
   PageTableEntry = AllocatePages (1);\r
+  ASSERT (PageTableEntry != NULL);\r
   //\r
   // Fill in 2M page entry.\r
   //\r
@@ -111,6 +112,7 @@ Split1GPageTo2M (
   PAGE_TABLE_ENTRY                      *PageDirectoryEntry;\r
 \r
   PageDirectoryEntry = AllocatePages (1);\r
+  ASSERT (PageDirectoryEntry != NULL);\r
   //\r
   // Fill in 1G page entry.\r
   //\r