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