]> git.proxmox.com Git - mirror_edk2.git/blobdiff - EdkModulePkg/Universal/StatusCode/Dxe/Common/DxeStatusCodeCommon.c
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1436 6f19259b...
[mirror_edk2.git] / EdkModulePkg / Universal / StatusCode / Dxe / Common / DxeStatusCodeCommon.c
index 1249284d5dd454dcb77963b56a809bf2834de04c..5bb54a201ee2a6d9f868a7f4267e33fa22ce204a 100644 (file)
@@ -39,6 +39,9 @@
                         Type EFI_STATUS_CODE_DATA is defined in "Related Definitions" below.  \r
                         The contents of this data type may have additional GUID-specific data.  The standard GUIDs and \r
                         their associated data structures are defined in the Intel? Platform Innovation Framework for EFI Status Codes Specification.\r
+\r
+  @return               Always return EFI_SUCCESS.\r
+\r
 **/\r
 EFI_STATUS \r
 EFIAPI\r
@@ -52,7 +55,8 @@ ReportDispatcher (
 \r
 //\r
 // Declaration of status code protocol.\r
-// \r
+//\r
+STATIC\r
 EFI_STATUS_CODE_PROTOCOL  mEfiStatusCodeProtocol  = {\r
   ReportDispatcher\r
 };\r
@@ -130,6 +134,9 @@ DxeStatusCodeDriverEntry (
                         Type EFI_STATUS_CODE_DATA is defined in "Related Definitions" below.  \r
                         The contents of this data type may have additional GUID-specific data.  The standard GUIDs and \r
                         their associated data structures are defined in the Intel? Platform Innovation Framework for EFI Status Codes Specification.\r
+\r
+  @return               Always return EFI_SUCCESS.\r
+\r
 **/\r
 EFI_STATUS \r
 EFIAPI\r
@@ -145,7 +152,7 @@ ReportDispatcher (
   // Use atom operation to avoid the reentant of report.\r
   // If current status is not zero, then the function is reentrancy.\r
   //\r
-  if (InterlockedCompareExchange32 (&gDxeStatusCode.StatusCodeNestStatus, 0, 1)) {\r
+  if (1 == InterlockedCompareExchange32 (&gDxeStatusCode.StatusCodeNestStatus, 0, 1)) {\r
     return EFI_DEVICE_ERROR;\r
   }\r
 \r