--- /dev/null
+/** @file\r
+\r
+Copyright (c) 2004 - 2008, Intel Corporation \r
+All rights reserved. This program and the accompanying materials \r
+are licensed and made available under the terms and conditions of the BSD License \r
+which accompanies this distribution. The full text of the license may be found at \r
+http://opensource.org/licenses/bsd-license.php \r
+ \r
+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:\r
+\r
+ EfiUtilityMsgs.h\r
+\r
+Abstract:\r
+\r
+ Defines and prototypes for common EFI utility error and debug messages.\r
+ \r
+**/\r
+\r
+#ifndef _EFI_UTILITY_MSGS_H_\r
+#define _EFI_UTILITY_MSGS_H_\r
+\r
+#include <Common/UefiBaseTypes.h>\r
+\r
+//\r
+// Log message print Level\r
+//\r
+#define VERBOSE_LOG_LEVEL 15\r
+#define WARNING_LOG_LEVEL 15\r
+#define INFO_LOG_LEVEL 20\r
+#define KEY_LOG_LEVEL 40\r
+#define ERROR_LOG_LEVLE 50\r
+\r
+//\r
+// Status codes returned by EFI utility programs and functions\r
+//\r
+#define STATUS_SUCCESS 0\r
+#define STATUS_WARNING 1\r
+#define STATUS_ERROR 2\r
+#define VOID void \r
+\r
+typedef int STATUS;\r
+\r
+#define MAX_LINE_LEN 0x200\r
+#define MAXIMUM_INPUT_FILE_NUM 10\r
+\r
+#ifdef __cplusplus\r
+extern "C" {\r
+#endif\r
+//\r
+// When we call Error() or Warning(), the module keeps track of the worst\r
+// case reported. GetUtilityStatus() will get the worst-case results, which\r
+// can be used as the return value from the app.\r
+//\r
+STATUS\r
+GetUtilityStatus (\r
+ VOID\r
+ );\r
+\r
+//\r
+// If someone prints an error message and didn't specify a source file name,\r
+// then we print the utility name instead. However they must tell us the\r
+// utility name early on via this function.\r
+//\r
+VOID\r
+SetUtilityName (\r
+ CHAR8 *ProgramName\r
+ )\r
+;\r
+\r
+VOID\r
+Error (\r
+ CHAR8 *FileName,\r
+ UINT32 LineNumber,\r
+ UINT32 ErrorCode,\r
+ CHAR8 *OffendingText,\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ )\r
+;\r
+\r
+VOID\r
+Warning (\r
+ CHAR8 *FileName,\r
+ UINT32 LineNumber,\r
+ UINT32 WarningCode,\r
+ CHAR8 *OffendingText,\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ )\r
+;\r
+\r
+VOID\r
+DebugMsg (\r
+ CHAR8 *FileName,\r
+ UINT32 LineNumber,\r
+ UINT32 MsgLevel,\r
+ CHAR8 *OffendingText,\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ )\r
+;\r
+\r
+VOID\r
+VerboseMsg (\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ );\r
+\r
+VOID\r
+NormalMsg (\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ );\r
+\r
+VOID\r
+KeyMsg (\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ );\r
+\r
+VOID\r
+SetPrintLevel (\r
+ UINT32 LogLevel\r
+ );\r
+\r
+VOID\r
+ParserSetPosition (\r
+ CHAR8 *SourceFileName,\r
+ UINT32 LineNum\r
+ )\r
+;\r
+\r
+VOID\r
+ParserError (\r
+ UINT32 ErrorCode,\r
+ CHAR8 *OffendingText,\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ )\r
+;\r
+\r
+VOID\r
+ParserWarning (\r
+ UINT32 ErrorCode,\r
+ CHAR8 *OffendingText,\r
+ CHAR8 *MsgFmt,\r
+ ...\r
+ )\r
+;\r
+\r
+VOID\r
+SetPrintLimits (\r
+ UINT32 NumErrors,\r
+ UINT32 NumWarnings,\r
+ UINT32 NumWarningsPlusErrors\r
+ )\r
+;\r
+\r
+#ifdef __cplusplus\r
+}\r
+#endif\r
+\r
+#endif // #ifndef _EFI_UTILITY_MSGS_H_\r