From nobody Sat May 4 02:37:01 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1523410096304700.407960436354; Tue, 10 Apr 2018 18:28:16 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 0134C2267F113; Tue, 10 Apr 2018 18:28:15 -0700 (PDT) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) (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 B732522618171 for ; Tue, 10 Apr 2018 18:28:13 -0700 (PDT) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Apr 2018 18:28:13 -0700 Received: from shwdeopenpsi114.ccr.corp.intel.com ([10.239.157.135]) by orsmga003.jf.intel.com with ESMTP; 10 Apr 2018 18:28:12 -0700 X-Original-To: edk2-devel@lists.01.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.120; helo=mga04.intel.com; envelope-from=dandan.bi@intel.com; receiver=edk2-devel@lists.01.org X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,434,1517904000"; d="scan'208";a="42364162" From: Dandan Bi To: edk2-devel@lists.01.org Date: Wed, 11 Apr 2018 09:27:12 +0800 Message-Id: <20180411012712.122468-1-dandan.bi@intel.com> X-Mailer: git-send-email 2.14.3.windows.1 Subject: [edk2] [patch] MdeModulePkg/FPDT: Add error message for unsupported case X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Liming Gao MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" We have updated performance infrastructure in previous commits: between https://github.com/tianocore/edk2/commit/73fef64f14d1b97ae9bd4705df3becc022= 391eba and https://github.com/tianocore/edk2/commit/115eae650bfd2be2c2bc37360f4a755065= e774c4 Update FPDT drivers to collect the performance data reported by gEdkiiFpdtExtendedFirmwarePerformanceGuid. The old implementation which collected performance data through gEfiFirmwarePerformanceGuid is not supported now. We should add error message to remind user for this unsupported case in case anyone use it by mistake. Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Dandan Bi Reviewed-by: Liming Gao --- .../Acpi/FirmwarePerformanceDataTableDxe/FirmwarePerformanceDxe.c | 3 += ++ .../Acpi/FirmwarePerformanceDataTableSmm/FirmwarePerformanceSmm.c | 5 += ++++ 2 files changed, 8 insertions(+) diff --git a/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableDxe/Fi= rmwarePerformanceDxe.c b/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDat= aTableDxe/FirmwarePerformanceDxe.c index e5a38121e9d..e719e9e482c 100644 --- a/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableDxe/FirmwareP= erformanceDxe.c +++ b/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableDxe/FirmwareP= erformanceDxe.c @@ -552,10 +552,13 @@ FpdtStatusCodeListenerDxe ( } else if (Data !=3D NULL && CompareGuid (&Data->Type, &gEdkiiFpdtExtend= edFirmwarePerformanceGuid)) { // // Get the Boot performance table and then install it to ACPI table. // CopyMem (&mReceivedAcpiBootPerformanceTable, Data + 1, Data->Size); + } else if (Data !=3D NULL && CompareGuid (&Data->Type, &gEfiFirmwarePerf= ormanceGuid)) { + DEBUG ((DEBUG_ERROR, "FpdtStatusCodeListenerDxe: Performance data repo= rted through gEfiFirmwarePerformanceGuid will not be collected by FirmwareP= erformanceDataTableDxe\n")); + Status =3D EFI_UNSUPPORTED; } else { // // Ignore else progress code. // Status =3D EFI_UNSUPPORTED; diff --git a/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableSmm/Fi= rmwarePerformanceSmm.c b/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDat= aTableSmm/FirmwarePerformanceSmm.c index d4ac849ed00..b011ec11030 100644 --- a/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableSmm/FirmwareP= erformanceSmm.c +++ b/MdeModulePkg/Universal/Acpi/FirmwarePerformanceDataTableSmm/FirmwareP= erformanceSmm.c @@ -104,10 +104,15 @@ FpdtStatusCodeListenerSmm ( =20 ReleaseSpinLock (&mSmmFpdtLock); return EFI_SUCCESS; } =20 + if (Data !=3D NULL && CompareGuid (&Data->Type, &gEfiFirmwarePerformance= Guid)) { + DEBUG ((DEBUG_ERROR, "FpdtStatusCodeListenerSmm: Performance data repo= rted through gEfiFirmwarePerformanceGuid will not be collected by FirmwareP= erformanceDataTableSmm\n")); + return EFI_UNSUPPORTED; + } + if ((Value !=3D PcdGet32 (PcdProgressCodeS3SuspendStart)) && (Value !=3D PcdGet32 (PcdProgressCodeS3SuspendEnd))) { return EFI_UNSUPPORTED; } =20 --=20 2.14.3.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel