summaryrefslogtreecommitdiffstats
path: root/UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c
diff options
context:
space:
mode:
Diffstat (limited to 'UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c')
-rw-r--r--UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c b/UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c
index 60a17b8fc2..efaab326bb 100644
--- a/UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c
+++ b/UefiPayloadPkg/Library/PlatformHookLib/PlatformHookLib.c
@@ -51,6 +51,10 @@ PlatformHookSerialPortInitialize (
UINT8 *GuidHob;
UNIVERSAL_PAYLOAD_GENERIC_HEADER *GenericHeader;
+ if (GetHobList () == NULL) {
+ return RETURN_SUCCESS;
+ }
+
GuidHob = GetFirstGuidHob (&gUniversalPayloadSerialPortInfoGuid);
if (GuidHob == NULL) {
return EFI_NOT_FOUND;