]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ArmPkg/ArmTrngLib: Remove ASSERTs in ArmTrngLibConstructor()
authorPierre Gondois <pierre.gondois@arm.com>
Thu, 24 Nov 2022 16:17:53 +0000 (17:17 +0100)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sat, 26 Nov 2022 14:42:41 +0000 (14:42 +0000)
Remove ASSERTs in ArmTrngLibConstructor() that prevent from
booting on DEBUG builds.

Signed-off-by: Pierre Gondois <Pierre.Gondois@arm.com>
Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
ArmPkg/Library/ArmTrngLib/ArmTrngLib.c

index 3278722320c885f16ddae01b7d9c637f4f1377c1..c2555f3ea6fe1845fa124b952674917639b6e467 100644 (file)
@@ -331,14 +331,12 @@ ArmTrngLibConstructor (
   ArmMonitorCall (&Parameters);\r
   Status = TrngStatusToReturnStatus ((INT32)Parameters.Arg0);\r
   if (RETURN_ERROR (Status)) {\r
-    ASSERT_RETURN_ERROR (Status);\r
     goto ErrorHandler;\r
   }\r
 \r
   // Cf [1] s2.1.3 'Caller responsibilities',\r
   // SMCCC version must be greater or equal than 1.1\r
   if ((INT32)Parameters.Arg0 < 0x10001) {\r
-    ASSERT_RETURN_ERROR (RETURN_UNSUPPORTED);\r
     goto ErrorHandler;\r
   }\r
 \r
@@ -350,14 +348,12 @@ ArmTrngLibConstructor (
   // Check that the required features are present.\r
   Status = GetArmTrngFeatures (ARM_SMC_ID_TRNG_RND, NULL);\r
   if (RETURN_ERROR (Status)) {\r
-    ASSERT_RETURN_ERROR (Status);\r
     goto ErrorHandler;\r
   }\r
 \r
   // Check if TRNG UUID is supported and if so trace the GUID.\r
   Status = GetArmTrngFeatures (ARM_SMC_ID_TRNG_GET_UUID, NULL);\r
   if (RETURN_ERROR (Status)) {\r
-    ASSERT_RETURN_ERROR (Status);\r
     goto ErrorHandler;\r
   }\r
 \r
@@ -365,7 +361,6 @@ ArmTrngLibConstructor (
 \r
   Status = GetArmTrngUuid (&Guid);\r
   if (RETURN_ERROR (Status)) {\r
-    ASSERT_RETURN_ERROR (Status);\r
     goto ErrorHandler;\r
   }\r
 \r