]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/BaseLib/SetJump.c
Fix invalid return status to sync with newest UEFI spec 2.1
[mirror_edk2.git] / MdePkg / Library / BaseLib / SetJump.c
index cb77d096116898112846780b1222e9e9b27259e2..7bd37fc135e926ee0d1215b2dacd503b680436b5 100644 (file)
   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
-  Module Name:  SetJump.c\r
-\r
 **/\r
 \r
+//\r
+// Include common header file for this module.\r
+//\r
+\r
+\r
 #include "BaseLibInternals.h"\r
 \r
 /**\r
@@ -22,7 +25,8 @@
   Checks ASSERT condition for JumpBuffer.\r
 \r
   If JumpBuffer is NULL, then ASSERT().\r
-  For IPF CPUs, if JumpBuffer is not aligned on a 16-byte boundary, then ASSERT().\r
+  If JumpBuffer is not aligned on a BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT\r
+  boundary, then ASSERT().\r
 \r
   @param  JumpBuffer    A pointer to CPU context buffer.\r
 \r
@@ -35,7 +39,5 @@ InternalAssertJumpBuffer (
 {\r
   ASSERT (JumpBuffer != NULL);\r
 \r
-#ifdef MDE_CPU_IPF\r
-  ASSERT (((UINTN)JumpBuffer & 0xf) == 0);\r
-#endif\r
+  ASSERT (((UINTN)JumpBuffer & ((BASE_LIBRARY_JUMP_BUFFER_ALIGNMENT - 1) >> 8)) == 0);\r
 }\r