]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/DxeHobLib/HobLib.c
Update Hob Instance to remove the unused InternalHobLib.h file.
[mirror_edk2.git] / MdePkg / Library / DxeHobLib / HobLib.c
index 605d42f80c379354aa337e474ec9e0dc36f66902..e13469534a58044ed0b876f76af4a0fdebcfba18 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
-  HOB Library.\r
+  HOB Library implemenation for Dxe Phase.\r
 \r
-  Copyright (c) 2006 - 2007, Intel Corporation<BR>\r
+  Copyright (c) 2006 - 2008, Intel Corporation<BR>\r
   All rights reserved. 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
@@ -22,7 +22,6 @@
 #include <Library/UefiLib.h>\r
 #include <Library/DebugLib.h>\r
 #include <Library/BaseMemoryLib.h>\r
-#include "HobLibInternal.h"\r
 \r
 STATIC VOID  *mHobList = NULL;\r
 \r
@@ -47,10 +46,11 @@ HobLibConstructor (
 {\r
   EFI_STATUS  Status;\r
 \r
-  Status = EfiGetSystemConfigurationTable (&gEfiHobListGuid, &mHobList);\r
+       Status = EfiGetSystemConfigurationTable (&gEfiHobListGuid, &mHobList);\r
   ASSERT_EFI_ERROR (Status);\r
   ASSERT (mHobList != NULL);\r
-  return Status;\r
+\r
+  return EFI_SUCCESS;\r
 }\r
 \r
 /**\r
@@ -201,7 +201,7 @@ GetFirstGuidHob (
   Get the Boot Mode from the HOB list.\r
 \r
   This function returns the system boot mode information from the \r
-  PHIT HOB in HOB list.\r
+  PHIT HOB in HOB list. If PHIT HOB is NULL, then ASSERT().\r
 \r
   @param  VOID\r
 \r
@@ -217,6 +217,7 @@ GetBootModeHob (
   EFI_HOB_HANDOFF_INFO_TABLE    *HandOffHob;\r
 \r
   HandOffHob = (EFI_HOB_HANDOFF_INFO_TABLE *) GetHobList ();\r
+  ASSERT (HandOffHob != NULL);\r
 \r
   return  HandOffHob->BootMode;\r
 }\r