]>
Commit | Line | Data |
---|---|---|
d042c6e8 | 1 | /** @file\r |
2 | Master header files for SmmCorePerformanceLib instance.\r | |
3 | \r | |
f0da4d7d | 4 | This header file holds the prototypes of the SMM Performance and PerformanceEx Protocol published by this\r |
d042c6e8 | 5 | library instance at its constructor.\r |
6 | \r | |
2001f84e | 7 | Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>\r |
9d510e61 | 8 | SPDX-License-Identifier: BSD-2-Clause-Patent\r |
d042c6e8 | 9 | \r |
10 | **/\r | |
d1102dba | 11 | \r |
d042c6e8 | 12 | #ifndef _SMM_CORE_PERFORMANCE_LIB_INTERNAL_H_\r |
13 | #define _SMM_CORE_PERFORMANCE_LIB_INTERNAL_H_\r | |
14 | \r | |
d042c6e8 | 15 | #include <Guid/Performance.h>\r |
137fb13d | 16 | #include <Guid/PerformanceMeasurement.h>\r |
2001f84e DB |
17 | #include <Guid/ExtendedFirmwarePerformance.h>\r |
18 | #include <Guid/FirmwarePerformance.h>\r | |
19 | #include <Guid/ZeroGuid.h>\r | |
20 | #include <Guid/EventGroup.h>\r | |
d042c6e8 | 21 | \r |
22 | #include <Library/SmmServicesTableLib.h>\r | |
23 | #include <Library/DebugLib.h>\r | |
24 | #include <Library/PerformanceLib.h>\r | |
25 | #include <Library/BaseLib.h>\r | |
26 | #include <Library/BaseMemoryLib.h>\r | |
27 | #include <Library/TimerLib.h>\r | |
28 | #include <Library/PcdLib.h>\r | |
d1102dba | 29 | #include <Library/UefiLib.h>\r |
d042c6e8 | 30 | #include <Library/UefiBootServicesTableLib.h>\r |
31 | #include <Library/MemoryAllocationLib.h>\r | |
32 | #include <Library/SynchronizationLib.h>\r | |
842b1242 | 33 | #include <Library/SmmMemLib.h>\r |
2001f84e DB |
34 | #include <Library/ReportStatusCodeLib.h>\r |
35 | #include <Library/DxeServicesLib.h>\r | |
36 | #include <Library/PeCoffGetEntryPointLib.h>\r | |
d042c6e8 | 37 | \r |
38 | #include <Protocol/SmmBase2.h>\r | |
2001f84e DB |
39 | #include <Protocol/LoadedImage.h>\r |
40 | #include <Protocol/DevicePathToText.h>\r | |
d042c6e8 | 41 | \r |
42 | //\r | |
137fb13d | 43 | // Interface declarations for SMM PerformanceMeasurement Protocol.\r |
f0da4d7d | 44 | //\r |
1436aea4 | 45 | \r |
f0da4d7d | 46 | /**\r |
137fb13d BD |
47 | Create performance record with event description and a timestamp.\r |
48 | \r | |
49 | @param CallerIdentifier - Image handle or pointer to caller ID GUID.\r | |
50 | @param Guid - Pointer to a GUID.\r | |
51 | @param String - Pointer to a string describing the measurement.\r | |
52 | @param TimeStamp - 64-bit time stamp.\r | |
53 | @param Address - Pointer to a location in memory relevant to the measurement.\r | |
54 | @param Identifier - Performance identifier describing the type of measurement.\r | |
55 | @param Attribute - The attribute of the measurement. According to attribute can create a start\r | |
56 | record for PERF_START/PERF_START_EX, or a end record for PERF_END/PERF_END_EX,\r | |
57 | or a general record for other Perf macros.\r | |
58 | \r | |
59 | @retval EFI_SUCCESS - Successfully created performance record.\r | |
60 | @retval EFI_OUT_OF_RESOURCES - Ran out of space to store the records.\r | |
61 | @retval EFI_INVALID_PARAMETER - Invalid parameter passed to function - NULL\r | |
62 | pointer or invalid PerfId.\r | |
f0da4d7d SZ |
63 | **/\r |
64 | EFI_STATUS\r | |
65 | EFIAPI\r | |
1436aea4 | 66 | CreatePerformanceMeasurement (\r |
e3917e22 MK |
67 | IN CONST VOID *CallerIdentifier OPTIONAL,\r |
68 | IN CONST VOID *Guid OPTIONAL,\r | |
69 | IN CONST CHAR8 *String OPTIONAL,\r | |
70 | IN UINT64 TimeStamp OPTIONAL,\r | |
71 | IN UINT64 Address OPTIONAL,\r | |
137fb13d BD |
72 | IN UINT32 Identifier,\r |
73 | IN PERF_MEASUREMENT_ATTRIBUTE Attribute\r | |
f0da4d7d SZ |
74 | );\r |
75 | \r | |
d042c6e8 | 76 | #endif\r |