]> git.proxmox.com Git - mirror_edk2.git/blobdiff - OvmfPkg/AcpiPlatformDxe/CloudHvAcpi.c
OvmfPkg/AcpiPlatformDxe: Return error if installing NotifyProtocol failed
[mirror_edk2.git] / OvmfPkg / AcpiPlatformDxe / CloudHvAcpi.c
index 8f90ea23996dd549e7cb5593503f583f88486495..d56eb074a987e8ccba7a9e12eaf385eb9b072db2 100644 (file)
@@ -89,12 +89,16 @@ InstallCloudHvTablesTdx (
   // ready.\r
   //\r
   ChAcpiHandle = NULL;\r
-  gBS->InstallProtocolInterface (\r
-         &ChAcpiHandle,\r
-         &gQemuAcpiTableNotifyProtocolGuid,\r
-         EFI_NATIVE_INTERFACE,\r
-         NULL\r
-         );\r
+  Status       = gBS->InstallProtocolInterface (\r
+                        &ChAcpiHandle,\r
+                        &gQemuAcpiTableNotifyProtocolGuid,\r
+                        EFI_NATIVE_INTERFACE,\r
+                        NULL\r
+                        );\r
+  if (EFI_ERROR (Status)) {\r
+    ASSERT_EFI_ERROR (Status);\r
+    return Status;\r
+  }\r
 \r
   return EFI_SUCCESS;\r
 }\r