From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 51B5021D490EC for ; Fri, 11 Aug 2017 01:33:10 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Aug 2017 01:35:30 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.41,356,1498546800"; d="scan'208";a="139063327" Received: from shwdeopenpsi068.ccr.corp.intel.com ([10.239.9.12]) by fmsmga006.fm.intel.com with ESMTP; 11 Aug 2017 01:35:29 -0700 From: Star Zeng To: edk2-devel@lists.01.org Cc: Star Zeng , Liming Gao , Cinnamon Shia Date: Fri, 11 Aug 2017 16:35:25 +0800 Message-Id: <1502440526-100840-2-git-send-email-star.zeng@intel.com> X-Mailer: git-send-email 2.7.0.windows.1 In-Reply-To: <1502440526-100840-1-git-send-email-star.zeng@intel.com> References: <1502440526-100840-1-git-send-email-star.zeng@intel.com> Subject: [PATCH 1/2] PerformancePkg DP: Init CustomCumulativeData.MinDur X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Aug 2017 08:33:10 -0000 Init CustomCumulativeData.MinDur to PERF_MAXDUR, otherwise the MinDur displayed for custom cumulative data will be always 0, but not the real shortest duration. Cc: Liming Gao Cc: Cinnamon Shia Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng --- PerformancePkg/Dp_App/Dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PerformancePkg/Dp_App/Dp.c b/PerformancePkg/Dp_App/Dp.c index 4cdc39edb42e..484ef2d50b80 100644 --- a/PerformancePkg/Dp_App/Dp.c +++ b/PerformancePkg/Dp_App/Dp.c @@ -382,7 +382,7 @@ InitializeDp ( if (CustomCumulativeToken != NULL) { CustomCumulativeData = AllocateZeroPool (sizeof (PERF_CUM_DATA)); ASSERT (CustomCumulativeData != NULL); - CustomCumulativeData->MinDur = 0; + CustomCumulativeData->MinDur = PERF_MAXDUR; CustomCumulativeData->MaxDur = 0; CustomCumulativeData->Count = 0; CustomCumulativeData->Duration = 0; -- 2.7.0.windows.1