///\r
/// Debug Mask Protocol function prototypes\r
///\r
+\r
+/**\r
+ Retrieves the current debug print error level mask for a module are returns\r
+ it in CurrentDebugMask.\r
+\r
+ @param This The protocol instance pointer.\r
+ @param CurrentDebugMask Pointer to the debug print error level mask that \r
+ is returned.\r
+\r
+ @retval EFI_SUCCESS The current debug print error level mask was\r
+ returned in CurrentDebugMask.\r
+ @retval EFI_INVALID_PARAMETER CurrentDebugMask is NULL.\r
+ @retval EFI_DEVICE_ERROR The current debug print error level mask could\r
+ not be retrieved.\r
+\r
+**/\r
EFI_STATUS\r
EFIAPI\r
GetDebugMask (\r
IN OUT UINTN *CurrentDebugMask \r
);\r
\r
+/**\r
+ Sets the current debug print error level mask for a module to the value\r
+ specified by NewDebugMask.\r
+\r
+ @param This The protocol instance pointer.\r
+ @param NewDebugMask The new debug print error level mask for this module.\r
+\r
+ @retval EFI_SUCCESS The current debug print error level mask was\r
+ set to the value specified by NewDebugMask.\r
+ @retval EFI_DEVICE_ERROR The current debug print error level mask could\r
+ not be set to the value specified by NewDebugMask.\r
+\r
+**/\r
EFI_STATUS\r
EFIAPI\r
SetDebugMask (\r
/// the global debug print error level mask value. The UefiBootServicesTableLib\r
/// is not used to prevent a circular dependency between these libraries.\r
///\r
-EFI_SYSTEM_TABLE *mST = NULL;\r
+EFI_SYSTEM_TABLE *mSystemTable = NULL;\r
\r
/**\r
The constructor function caches the PCI Express Base Address and creates a \r
//\r
// Install Debug Mask Protocol onto ImageHandle\r
// \r
- mST = SystemTable;\r
+ mSystemTable = SystemTable;\r
Status = SystemTable->BootServices->InstallMultipleProtocolInterfaces (\r
&ImageHandle,\r
&gEfiDebugMaskProtocolGuid, &mDebugMaskProtocol,\r
// This case should only occur if debug print is generated by a library\r
// constructor for this module\r
//\r
- if (mST == NULL) {\r
+ if (mSystemTable == NULL) {\r
return PcdGet32 (PcdDebugPrintErrorLevel);\r
}\r
\r
//\r
// Make sure the TPL Level is low enough for EFI Variable Services to be called\r
//\r
- CurrentTpl = mST->BootServices->RaiseTPL (TPL_HIGH_LEVEL);\r
- mST->BootServices->RestoreTPL (CurrentTpl);\r
+ CurrentTpl = mSystemTable->BootServices->RaiseTPL (TPL_HIGH_LEVEL);\r
+ mSystemTable->BootServices->RestoreTPL (CurrentTpl);\r
if (CurrentTpl <= TPL_CALLBACK) {\r
//\r
// Attempt to retrieve the global debug print error level mask from the \r
// EFI Variable\r
//\r
Size = sizeof (GlobalErrorLevel);\r
- Status = mST->RuntimeServices->GetVariable (\r
+ Status = mSystemTable->RuntimeServices->GetVariable (\r
DEBUG_MASK_VARIABLE_NAME, \r
&gEfiGenericVariableGuid, \r
NULL, \r
\r
/**\r
Sets the global debug print error level mask fpr the entire platform.\r
-\r
- @retval TRUE The debug print error level mask was sucessfully set.\r
- @retval FALSE The debug print error level mask could not be set.\r
+ \r
+ @param ErrorLevel Global debug print error level\r
+ \r
+ @retval TRUE The debug print error level mask was sucessfully set.\r
+ @retval FALSE The debug print error level mask could not be set.\r
\r
**/\r
BOOLEAN\r
//\r
// Make sure the constructor has been executed\r
//\r
- if (mST != NULL) {\r
+ if (mSystemTable != NULL) {\r
//\r
// Make sure the TPL Level is low enough for EFI Variable Services\r
//\r
- CurrentTpl = mST->BootServices->RaiseTPL (TPL_HIGH_LEVEL);\r
- mST->BootServices->RestoreTPL (CurrentTpl);\r
+ CurrentTpl = mSystemTable->BootServices->RaiseTPL (TPL_HIGH_LEVEL);\r
+ mSystemTable->BootServices->RestoreTPL (CurrentTpl);\r
if (CurrentTpl <= TPL_CALLBACK) {\r
//\r
// Attempt to store the global debug print error level mask in an EFI Variable\r
//\r
GlobalErrorLevel = (UINTN)ErrorLevel;\r
Size = sizeof (GlobalErrorLevel);\r
- Status = mST->RuntimeServices->SetVariable (\r
+ Status = mSystemTable->RuntimeServices->SetVariable (\r
DEBUG_MASK_VARIABLE_NAME, \r
&gEfiGenericVariableGuid, \r
(EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS),\r