From 32c8c88df50e0757a3fddfe9c81b54d266a6d4e7 Mon Sep 17 00:00:00 2001 From: Samer El-Haj-Mahmoud Date: Mon, 2 Nov 2015 02:38:24 +0000 Subject: MdeModulePkg: Add DEBUG statement when reaching max perf log entries Add a DEBUG statement when the number of PEI perf log entries exceeds PcdMaxPeiPerformanceLogEntries Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Samer El-Haj-Mahmoud Reviewed-by: Star Zeng git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18714 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'MdeModulePkg') diff --git a/MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.c b/MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.c index 0b5a717caa..9674bbc621 100644 --- a/MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.c +++ b/MdeModulePkg/Library/PeiPerformanceLib/PeiPerformanceLib.c @@ -7,6 +7,7 @@ number of performance logging entry is specified by PcdMaxPeiPerformanceLogEntries. Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.
+(C) Copyright 2015 Hewlett Packard Enterprise Development LP
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -183,6 +184,7 @@ StartPerformanceMeasurementEx ( InternalGetPerformanceHobLog (&PeiPerformanceLog, &PeiPerformanceIdArray); if (PeiPerformanceLog->NumberOfEntries >= PcdGet8 (PcdMaxPeiPerformanceLogEntries)) { + DEBUG ((DEBUG_ERROR, "PEI performance log array out of resources\n")); return RETURN_OUT_OF_RESOURCES; } Index = PeiPerformanceLog->NumberOfEntries++; -- cgit v1.2.3