]> git.proxmox.com Git - mirror_edk2.git/blob - IntelFrameworkModulePkg/Library/SmmRuntimeDxeReportStatusCodeLibFramework/ReportStatusCodeLibInternal.h
IntelFrameworkModulePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / IntelFrameworkModulePkg / Library / SmmRuntimeDxeReportStatusCodeLibFramework / ReportStatusCodeLibInternal.h
1 /** @file
2 Internal Header file of Report Status Code Library for RUNTIME
3 DXE Phase.
4
5 Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
6 SPDX-License-Identifier: BSD-2-Clause-Patent
7
8 **/
9 #ifndef __REPORT_STATUS_CODE_LIB_INTERNAL__H__
10 #define __REPORT_STATUS_CODE_LIB_INTERNAL__H__
11
12 #include <FrameworkSmm.h>
13
14 #include <Library/ReportStatusCodeLib.h>
15 #include <Library/DebugLib.h>
16 #include <Library/BaseLib.h>
17 #include <Library/BaseMemoryLib.h>
18 #include <Library/PcdLib.h>
19 #include <Library/UefiRuntimeServicesTableLib.h>
20 #include <Library/UefiBootServicesTableLib.h>
21 #include <Library/DevicePathLib.h>
22 #include <Library/MemoryAllocationLib.h>
23
24 #include <Guid/StatusCodeDataTypeId.h>
25 #include <Guid/StatusCodeDataTypeDebug.h>
26 #include <Guid/EventGroup.h>
27
28 #include <Protocol/SmmStatusCode.h>
29 #include <Protocol/StatusCode.h>
30 #include <Protocol/SmmBase.h>
31
32
33 extern EFI_STATUS_CODE_DATA *mStatusCodeData;
34
35 /**
36 Internal worker function that reports a status code through the status code service.
37
38 If status code service is not cached, then this function checks if status code service is
39 available in system. If status code service is not available, then EFI_UNSUPPORTED is
40 returned. If status code service is present, then it is cached in mReportStatusCode.
41 Finally this function reports status code through the status code service.
42
43 @param Type Status code type.
44 @param Value Status code value.
45 @param Instance Status code instance number.
46 @param CallerId Pointer to a GUID that identifies the caller of this
47 function. This is an optional parameter that may be
48 NULL.
49 @param Data Pointer to the extended data buffer. This is an
50 optional parameter that may be NULL.
51
52 @retval EFI_SUCCESS The status code was reported.
53 @retval EFI_UNSUPPORTED Status code service is not available.
54 @retval EFI_UNSUPPORTED Status code type is not supported.
55
56 **/
57 EFI_STATUS
58 InternalReportStatusCode (
59 IN EFI_STATUS_CODE_TYPE Type,
60 IN EFI_STATUS_CODE_VALUE Value,
61 IN UINT32 Instance,
62 IN CONST EFI_GUID *CallerId OPTIONAL,
63 IN EFI_STATUS_CODE_DATA *Data OPTIONAL
64 );
65
66 #endif
67