Without this fix, the "%r" format specifier prints eg. "0000001A"
instead of "Security Violation" for EFI_SECURITY_VIOLATION.

Contributed-under: TianoCore Contribution Agreement 1.0

Signed-off-by: Gary Ching-Pang Lin <g...@suse.com>
---
 .../Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c      | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git 
a/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c
 
b/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c
index 3258b01..4a2168c 100644
--- 
a/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c
+++ 
b/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c
@@ -23,7 +23,7 @@ Abstract:
 #include "PrintLibInternal.h"
 
 #define WARNING_STATUS_NUMBER         4
-#define ERROR_STATUS_NUMBER           24
+#define ERROR_STATUS_NUMBER           31
 #define ASSERT_UNICODE_BUFFER(Buffer) ASSERT ((((UINTN) (Buffer)) & 0x01) == 0)
 
 GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8 *StatusString [] = {
@@ -55,7 +55,14 @@ GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8 *StatusString [] = 
{
   "Aborted",                      //  RETURN_ABORTED                = 21 | 
MAX_BIT
   "ICMP Error",                   //  RETURN_ICMP_ERROR             = 22 | 
MAX_BIT
   "TFTP Error",                   //  RETURN_TFTP_ERROR             = 23 | 
MAX_BIT
-  "Protocol Error"                //  RETURN_PROTOCOL_ERROR         = 24 | 
MAX_BIT
+  "Protocol Error",               //  RETURN_PROTOCOL_ERROR         = 24 | 
MAX_BIT
+  "Incompatible Version",         //  RETURN_INCOMPATIBLE_VERSION   = 25 | 
MAX_BIT
+  "Security Violation",           //  RETURN_SECURITY_VIOLATION     = 26 | 
MAX_BIT
+  "CRC Error",                    //  RETURN_CRC_ERROR              = 27 | 
MAX_BIT
+  "End of Media",                 //  RETURN_END_OF_MEDIA           = 28 | 
MAX_BIT
+  "Reserved (29)",                //  RESERVED                      = 29 | 
MAX_BIT
+  "Reserved (30)",                //  RESERVED                      = 30 | 
MAX_BIT
+  "End of File"                   //  RETURN_END_OF_FILE            = 31 | 
MAX_BIT
 };
 
 /**
-- 
1.8.1.4


------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to