From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=missing; spf=fail (domain: intel.com, ip: , mailfrom: zhichao.gao@intel.com) Received: from mga17.intel.com (mga17.intel.com []) by groups.io with SMTP; Mon, 10 Jun 2019 00:29:21 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Jun 2019 00:29:21 -0700 X-ExtLoop1: 1 Received: from fieedk001.ccr.corp.intel.com ([10.239.33.119]) by fmsmga001.fm.intel.com with ESMTP; 10 Jun 2019 00:29:20 -0700 From: "Gao, Zhichao" To: devel@edk2.groups.io Cc: Bret Barkelew , Chao Zhang , Jiewen Yao , Jian Wang Subject: [PATCH 4/6] SecurityPkg/Tcg2Dxe: Change performance code Date: Mon, 10 Jun 2019 15:28:53 +0800 Message-Id: <20190610072855.2800-5-zhichao.gao@intel.com> X-Mailer: git-send-email 2.21.0.windows.1 In-Reply-To: <20190610072855.2800-1-zhichao.gao@intel.com> References: <20190610072855.2800-1-zhichao.gao@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Bret Barkelew REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1888 Use PERF_FUNCTION_BEGIN and PERF_FUNCTION_END to replace PERF_START_EX and PERF_FUNCTION_END. Cc: Chao Zhang Cc: Jiewen Yao Cc: Jian Wang Signed-off-by: Zhichao Gao --- SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c b/SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c index a2729457b7..001e0aac4d 100644 --- a/SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c +++ b/SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c @@ -45,8 +45,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include -#define PERF_ID_TCG2_DXE 0x3120 - typedef struct { CHAR16 *VariableName; EFI_GUID *VendorGuid; @@ -2250,7 +2248,7 @@ OnReadyToBoot ( EFI_STATUS Status; TPM_PCRINDEX PcrIndex; - PERF_START_EX (mImageHandle, "EventRec", "Tcg2Dxe", 0, PERF_ID_TCG2_DXE); + PERF_FUNCTION_BEGIN (); if (mBootAttempts == 0) { // @@ -2332,7 +2330,7 @@ OnReadyToBoot ( // Increase boot attempt counter. // mBootAttempts++; - PERF_END_EX (mImageHandle, "EventRec", "Tcg2Dxe", 0, PERF_ID_TCG2_DXE + 1); + PERF_FUNCTION_END (); } /** -- 2.21.0.windows.1