Add an example case for the usage of
PERF_CALLBACK_BEGIN/PERF_CALLBACK_END
Cc: Liming Gao <liming.gao@intel.com>
Cc: Chao Zhang <chao.b.zhang@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Chao Zhang<chao.b.zhang@intel.com>
\r
MeasuredHobData = NULL;\r
\r
\r
MeasuredHobData = NULL;\r
\r
+ PERF_CALLBACK_BEGIN (&gEfiEndOfPeiSignalPpiGuid);\r
+\r
//\r
// Create a Guid hob to save all measured Fv\r
//\r
//\r
// Create a Guid hob to save all measured Fv\r
//\r
CopyMem (&MeasuredHobData->MeasuredFvBuf[mMeasuredBaseFvIndex] , mMeasuredChildFvInfo, sizeof(EFI_PLATFORM_FIRMWARE_BLOB) * (mMeasuredChildFvIndex));\r
}\r
\r
CopyMem (&MeasuredHobData->MeasuredFvBuf[mMeasuredBaseFvIndex] , mMeasuredChildFvInfo, sizeof(EFI_PLATFORM_FIRMWARE_BLOB) * (mMeasuredChildFvIndex));\r
}\r
\r
+ PERF_CALLBACK_END (&gEfiEndOfPeiSignalPpiGuid);\r
+\r
return EFI_SUCCESS;\r
}\r
\r
return EFI_SUCCESS;\r
}\r
\r
#include <Library/Tpm12DeviceLib.h>\r
#include <Library/Tpm12CommandLib.h>\r
#include <Library/BaseCryptLib.h>\r
#include <Library/Tpm12DeviceLib.h>\r
#include <Library/Tpm12CommandLib.h>\r
#include <Library/BaseCryptLib.h>\r
+#include <Library/PerformanceLib.h>\r
\r
BOOLEAN mImageInMemory = FALSE;\r
\r
\r
BOOLEAN mImageInMemory = FALSE;\r
\r
\r
MeasuredHobData = NULL;\r
\r
\r
MeasuredHobData = NULL;\r
\r
+ PERF_CALLBACK_BEGIN (&gEfiEndOfPeiSignalPpiGuid);\r
+\r
//\r
// Create a Guid hob to save all measured Fv\r
//\r
//\r
// Create a Guid hob to save all measured Fv\r
//\r
CopyMem (&MeasuredHobData->MeasuredFvBuf[mMeasuredBaseFvIndex] , mMeasuredChildFvInfo, sizeof(EFI_PLATFORM_FIRMWARE_BLOB) * (mMeasuredChildFvIndex));\r
}\r
\r
CopyMem (&MeasuredHobData->MeasuredFvBuf[mMeasuredBaseFvIndex] , mMeasuredChildFvInfo, sizeof(EFI_PLATFORM_FIRMWARE_BLOB) * (mMeasuredChildFvIndex));\r
}\r
\r
+ PERF_CALLBACK_END (&gEfiEndOfPeiSignalPpiGuid);\r
+\r
return EFI_SUCCESS;\r
}\r
\r
return EFI_SUCCESS;\r
}\r
\r
MemoryAllocationLib\r
ReportStatusCodeLib\r
Tpm12CommandLib\r
MemoryAllocationLib\r
ReportStatusCodeLib\r
Tpm12CommandLib\r
\r
[Guids]\r
gTcgEventEntryHobGuid ## PRODUCES ## HOB\r
\r
[Guids]\r
gTcgEventEntryHobGuid ## PRODUCES ## HOB\r