From nobody Sat May 4 10:59:06 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 1519709889845504.10574314537735; Mon, 26 Feb 2018 21:38:09 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 8B0E521F0DA4D; Mon, 26 Feb 2018 21:32:03 -0800 (PST) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (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 AF5B12034D8CB for ; Mon, 26 Feb 2018 21:32:02 -0800 (PST) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Feb 2018 21:38:08 -0800 Received: from shwde7172.ccr.corp.intel.com ([10.239.9.15]) by orsmga004.jf.intel.com with ESMTP; 26 Feb 2018 21:38:07 -0800 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=134.134.136.31; helo=mga06.intel.com; envelope-from=liming.gao@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.47,398,1515484800"; d="scan'208";a="178348388" From: Liming Gao To: edk2-devel@lists.01.org Date: Tue, 27 Feb 2018 13:38:05 +0800 Message-Id: <1519709885-6772-1-git-send-email-liming.gao@intel.com> X-Mailer: git-send-email 2.8.0.windows.1 Subject: [edk2] [Patch] MdeModulePkg PCD: Add more debug message to show SkuId update X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Star Zeng 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" Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Cc: Star Zeng Reviewed-by: Star Zeng --- MdeModulePkg/Universal/PCD/Dxe/Pcd.c | 6 +++++- MdeModulePkg/Universal/PCD/Pei/Pcd.c | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Universal/PCD/Dxe/Pcd.c b/MdeModulePkg/Universal/= PCD/Dxe/Pcd.c index 26485f1..1b19e38 100644 --- a/MdeModulePkg/Universal/PCD/Dxe/Pcd.c +++ b/MdeModulePkg/Universal/PCD/Dxe/Pcd.c @@ -286,10 +286,13 @@ DxePcdSetSku ( UINTN Index; EFI_STATUS Status; =20 + DEBUG ((DEBUG_INFO, "PcdDxe - SkuId 0x%lx is to be set.\n", (SKU_ID) Sku= Id)); + if (SkuId =3D=3D mPcdDatabase.DxeDb->SystemSkuId) { // // The input SKU Id is equal to current SKU Id, return directly. // + DEBUG ((DEBUG_INFO, "PcdDxe - SkuId is same to current system Sku.\n")= ); return; } =20 @@ -308,6 +311,7 @@ DxePcdSetSku ( SkuIdTable =3D (SKU_ID *) ((UINT8 *) mPcdDatabase.DxeDb + mPcdDatabase.D= xeDb->SkuIdTableOffset); for (Index =3D 0; Index < SkuIdTable[0]; Index++) { if (SkuId =3D=3D SkuIdTable[Index + 1]) { + DEBUG ((DEBUG_INFO, "PcdDxe - SkuId is found in SkuId table.\n")); Status =3D UpdatePcdDatabase (SkuId, TRUE); if (!EFI_ERROR (Status)) { mPcdDatabase.DxeDb->SystemSkuId =3D (SKU_ID) SkuId; @@ -320,7 +324,7 @@ DxePcdSetSku ( // // Invalid input SkuId, the default SKU Id will be still used for the sy= stem. // - DEBUG ((DEBUG_INFO, "PcdDxe - Invalid input SkuId, the default SKU Id wi= ll be still used.\n")); + DEBUG ((DEBUG_ERROR, "PcdDxe - Invalid input SkuId, the default SKU Id w= ill be still used.\n")); return; } =20 diff --git a/MdeModulePkg/Universal/PCD/Pei/Pcd.c b/MdeModulePkg/Universal/= PCD/Pei/Pcd.c index f821395..8d9328b 100644 --- a/MdeModulePkg/Universal/PCD/Pei/Pcd.c +++ b/MdeModulePkg/Universal/PCD/Pei/Pcd.c @@ -475,12 +475,15 @@ PeiPcdSetSku ( PCD_DATABASE_SKU_DELTA *SkuDelta; PCD_DATA_DELTA *SkuDeltaData; =20 + DEBUG ((DEBUG_INFO, "PcdPei - SkuId 0x%lx is to be set.\n", (SKU_ID) Sku= Id)); + PeiPcdDb =3D GetPcdDatabase(); =20 if (SkuId =3D=3D PeiPcdDb->SystemSkuId) { // // The input SKU Id is equal to current SKU Id, return directly. // + DEBUG ((DEBUG_INFO, "PcdPei - SkuId is same to current system Sku.\n")= ); return; } =20 @@ -499,6 +502,7 @@ PeiPcdSetSku ( SkuIdTable =3D (SKU_ID *) ((UINT8 *) PeiPcdDb + PeiPcdDb->SkuIdTableOffs= et); for (Index =3D 0; Index < SkuIdTable[0]; Index++) { if (SkuId =3D=3D SkuIdTable[Index + 1]) { + DEBUG ((DEBUG_INFO, "PcdPei - SkuId is found in SkuId table.\n")); break; } } @@ -570,7 +574,7 @@ PeiPcdSetSku ( // // Invalid input SkuId, the default SKU Id will be still used for the sy= stem. // - DEBUG ((EFI_D_INFO, "PcdPei - Invalid input SkuId, the default SKU Id wi= ll be still used.\n")); + DEBUG ((DEBUG_ERROR, "PcdPei - Invalid input SkuId, the default SKU Id w= ill be still used.\n")); =20 return; } --=20 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel