From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059422128215.44553631102565; Thu, 21 Sep 2017 22:50:22 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 5088521ECCB3F; Thu, 21 Sep 2017 22:47:11 -0700 (PDT) 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 66B9A21E1B757 for ; Thu, 21 Sep 2017 22:47:10 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:18 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:17 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738582" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:01 +0800 Message-Id: <20170922055014.27288-2-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 01/14] ShellPkg/dh: display all the protocol names in a single line 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c | 36 ++++++++++++++----= ---- .../UefiShellDriver1CommandsLib.uni | 1 + 2 files changed, 25 insertions(+), 12 deletions(-) diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c b/ShellPkg/L= ibrary/UefiShellDriver1CommandsLib/Dh.c index 170a868e07..3694e501b6 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c @@ -319,7 +319,7 @@ GetProtocolInfoString( if (!Verbose) { StrnCatGrow(&RetVal, &Size, L"(", 0); StrnCatGrow(&RetVal, &Size, Temp, 0); - StrnCatGrow(&RetVal, &Size, L")\r\n", 0); + StrnCatGrow(&RetVal, &Size, L")", 0); } else { StrnCatGrow(&RetVal, &Size, Separator, 0); StrnCatGrow(&RetVal, &Size, Temp, 0); @@ -802,17 +802,29 @@ DoDhByHandle( ProtocolInfoString=3D=3DNULL?L"":ProtocolInfoString ); } else { - ProtocolInfoString =3D GetProtocolInfoString(TheHandle, Language, L"= \r\n", Verbose, TRUE); - ShellPrintHiiEx( - -1, - -1, - NULL, - STRING_TOKEN (STR_DH_OUTPUT_SINGLE), - gShellDriver1HiiHandle, - ConvertHandleToHandleIndex(TheHandle), - TheHandle, - ProtocolInfoString=3D=3DNULL?L"":ProtocolInfoString - ); + ProtocolInfoString =3D GetProtocolInfoString(TheHandle, Language, Ve= rbose ? L"\r\n" : L" ", Verbose, TRUE); + if (Verbose) { + ShellPrintHiiEx( + -1, + -1, + NULL, + STRING_TOKEN (STR_DH_OUTPUT_SINGLE), + gShellDriver1HiiHandle, + ConvertHandleToHandleIndex(TheHandle), + TheHandle, + ProtocolInfoString=3D=3DNULL?L"":ProtocolInfoString + ); + } else { + ShellPrintHiiEx( + -1, + -1, + NULL, + STRING_TOKEN (STR_DH_OUTPUT_SINGLE_D), + gShellDriver1HiiHandle, + ConvertHandleToHandleIndex(TheHandle), + ProtocolInfoString=3D=3DNULL?L"":ProtocolInfoString + ); + } } =20 if (DriverInfo) { diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1C= ommandsLib.uni b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriv= er1CommandsLib.uni index 05101f3782..07e8657113 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni @@ -106,6 +106,7 @@ #string STR_DH_OUTPUT_ALL_HEADER #language en-US "Handle dump\r\n" #string STR_DH_OUTPUT_GUID_HEADER #language en-US "Handle dump by protocol= '%g'\r\n" #string STR_DH_OUTPUT_NAME_HEADER #language en-US "Handle dump by protocol= '%s'\r\n" +#string STR_DH_OUTPUT_SINGLE_D #language en-US "%H%02x%N: %s\r\n" #string STR_DH_OUTPUT_SINGLE #language en-US "%H%02x%N: %x\r\n%s" #string STR_DH_OUTPUT_SFO #language en-US "%s, %s, %s, %H%02x%N, %= s, %s\r\n" #string STR_DH_OUTPUT_DRIVER1 #language en-US " Controller Name := %B%s%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059423440196.3026661048233; Thu, 21 Sep 2017 22:50:23 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 8CE052095E4E6; Thu, 21 Sep 2017 22:47:13 -0700 (PDT) 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 F248D2095E4E2 for ; Thu, 21 Sep 2017 22:47:11 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:19 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:18 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738587" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:02 +0800 Message-Id: <20170922055014.27288-3-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 02/14] ShellPkg/dh: change the key information color from blue to hilight 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li The blue text is very hard to see. Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiShellDriver1CommandsLib.uni | 40 +++++++++++-------= ---- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1C= ommandsLib.uni b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriv= er1CommandsLib.uni index 07e8657113..55008f5057 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni @@ -109,26 +109,26 @@ #string STR_DH_OUTPUT_SINGLE_D #language en-US "%H%02x%N: %s\r\n" #string STR_DH_OUTPUT_SINGLE #language en-US "%H%02x%N: %x\r\n%s" #string STR_DH_OUTPUT_SFO #language en-US "%s, %s, %s, %H%02x%N, %= s, %s\r\n" -#string STR_DH_OUTPUT_DRIVER1 #language en-US " Controller Name := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER2 #language en-US " Device Path := %B%s%N\r\n" - " Controller Type := %B%s%N\r\n" - " Configuration := %B%s%N\r\n" - " Diagnostics := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER3 #language en-US " Managed by := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER4A #language en-US " Drv[%H%02x%N] = : Image(%B%s%N)r\n" -#string STR_DH_OUTPUT_DRIVER4B #language en-US " Drv[%H%02x%N] = : %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER5 #language en-US " Parent Controllers := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER5B #language en-US " Parent[%H%02x%N] = : %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER6 #language en-US " Child Controllers := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER6B #language en-US " Child[%H%02x%N] = : %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER7 #language en-US " Driver Name [%H%02x%= N] : %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER7B #language en-US " Driver Image Name := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER8 #language en-US " Driver Version := %B%08x%N\r\n" - " Driver Type := %B%s%N\r\n" - " Configuration := %B%s%N\r\n" - " Diagnostics := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER9 #language en-US " Managing := %B%s%N\r\n" -#string STR_DH_OUTPUT_DRIVER9B #language en-US " Ctrl[%H%02x%N] = : %B%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER1 #language en-US " Controller Name := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER2 #language en-US " Device Path := %H%s%N\r\n" + " Controller Type := %H%s%N\r\n" + " Configuration := %H%s%N\r\n" + " Diagnostics := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER3 #language en-US " Managed by := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER4A #language en-US " Drv[%H%02x%N] = : Image(%H%s%N)r\n" +#string STR_DH_OUTPUT_DRIVER4B #language en-US " Drv[%H%02x%N] = : %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER5 #language en-US " Parent Controllers := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER5B #language en-US " Parent[%H%02x%N] = : %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER6 #language en-US " Child Controllers := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER6B #language en-US " Child[%H%02x%N] = : %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER7 #language en-US " Driver Name [%H%02x%= N] : %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER7B #language en-US " Driver Image Name := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER8 #language en-US " Driver Version := %H%08x%N\r\n" + " Driver Type := %H%s%N\r\n" + " Configuration := %H%s%N\r\n" + " Diagnostics := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER9 #language en-US " Managing := %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER9B #language en-US " Ctrl[%H%02x%N] = : %H%s%N\r\n" =20 #string STR_DEV_TREE_OUTPUT #language en-US "Ctrl[%H%02x%N] %s\r\n" =20 --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059425661600.1582100061664; Thu, 21 Sep 2017 22:50:25 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id C138B2095E4E9; Thu, 21 Sep 2017 22:47:13 -0700 (PDT) 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 5E6FB2095E4E2 for ; Thu, 21 Sep 2017 22:47:12 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:20 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:19 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738593" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:03 +0800 Message-Id: <20170922055014.27288-4-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 03/14] ShellPkg/dh: fix the error display "Child Controllers" to "Managing". 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c | 6 ++= +--- .../UefiShellDriver1CommandsLib/UefiShellDriver1CommandsLib.uni | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c b/ShellPkg/L= ibrary/UefiShellDriver1CommandsLib/Dh.c index 3694e501b6..f37f7e9a9e 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c @@ -705,7 +705,7 @@ DisplayDriverModelHandle ( -1,=20 -1,=20 NULL,=20 - STRING_TOKEN (STR_DH_OUTPUT_DRIVER6),=20 + STRING_TOKEN (STR_DH_OUTPUT_DRIVER9), gShellDriver1HiiHandle,=20 L"None" ); @@ -714,7 +714,7 @@ DisplayDriverModelHandle ( -1,=20 -1,=20 NULL,=20 - STRING_TOKEN (STR_DH_OUTPUT_DRIVER6),=20 + STRING_TOKEN (STR_DH_OUTPUT_DRIVER9), gShellDriver1HiiHandle,=20 L"" ); @@ -746,7 +746,7 @@ DisplayDriverModelHandle ( -1,=20 -1,=20 NULL,=20 - STRING_TOKEN (STR_DH_OUTPUT_DRIVER6B), + STRING_TOKEN (STR_DH_OUTPUT_DRIVER6C), gShellDriver1HiiHandle, ConvertHandleToHandleIndex(ChildControllerHandleBuffer[ChildIn= dex]), TempStringPointer!=3DNULL?TempStringPointer:L"" diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1C= ommandsLib.uni b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriv= er1CommandsLib.uni index 55008f5057..e4bff68838 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/UefiShellDriver1Commands= Lib.uni @@ -121,6 +121,7 @@ #string STR_DH_OUTPUT_DRIVER5B #language en-US " Parent[%H%02x%N] = : %H%s%N\r\n" #string STR_DH_OUTPUT_DRIVER6 #language en-US " Child Controllers := %H%s%N\r\n" #string STR_DH_OUTPUT_DRIVER6B #language en-US " Child[%H%02x%N] = : %H%s%N\r\n" +#string STR_DH_OUTPUT_DRIVER6C #language en-US " Child[%H%02x%N] = : %H%s%N\r\n" #string STR_DH_OUTPUT_DRIVER7 #language en-US " Driver Name [%H%02x%= N] : %H%s%N\r\n" #string STR_DH_OUTPUT_DRIVER7B #language en-US " Driver Image Name := %H%s%N\r\n" #string STR_DH_OUTPUT_DRIVER8 #language en-US " Driver Version := %H%08x%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059428025711.7085244493429; Thu, 21 Sep 2017 22:50:28 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 05ABB2095E4EC; Thu, 21 Sep 2017 22:47:14 -0700 (PDT) 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 38FA22095E4E2 for ; Thu, 21 Sep 2017 22:47:13 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:20 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:20 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738596" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:04 +0800 Message-Id: <20170922055014.27288-5-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 04/14] ShellPkg/dh: Display the protocol instance pointer value for "-v" 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c b/ShellPkg/L= ibrary/UefiShellDriver1CommandsLib/Dh.c index f37f7e9a9e..7d06163a7b 100644 --- a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c +++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c @@ -286,6 +286,8 @@ GetProtocolInfoString( UINTN Size; CHAR16 *Temp; CHAR16 GuidStr[40]; + VOID *instance; + CHAR16 InstanceStr[17]; =20 ProtocolGuidArray =3D NULL; RetVal =3D NULL; @@ -312,6 +314,17 @@ GetProtocolInfoString( FreePool(Temp); } StrnCatGrow(&RetVal, &Size, L"%N", 0); + + if(Verbose) { + Status =3D gBS->HandleProtocol (TheHandle, ProtocolGuidArray[Proto= colIndex], &instance); + if (!EFI_ERROR (Status)) { + StrnCatGrow (&RetVal, &Size, L"(%H", 0); + UnicodeSPrint (InstanceStr, sizeof (InstanceStr), L"%x", instanc= e); + StrnCatGrow (&RetVal, &Size, InstanceStr, 0); + StrnCatGrow (&RetVal, &Size, L"%N)", 0); + } + } + if (ExtraInfo) { Temp =3D GetProtocolInformationDump(TheHandle, ProtocolGuidArray[P= rotocolIndex], Verbose); if (Temp !=3D NULL) { --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059430630855.6781493963935; Thu, 21 Sep 2017 22:50:30 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 42ECD2095E4E5; Thu, 21 Sep 2017 22:47:17 -0700 (PDT) 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 3089B2095E4EE for ; Thu, 21 Sep 2017 22:47:14 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:21 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:20 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738601" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:05 +0800 Message-Id: <20170922055014.27288-6-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 05/14] ShellPkg/dh: Modify the dump of "ImageDevicePath" and "DevicePath" 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 68 +++++++++++++++---= ---- 1 file changed, 46 insertions(+), 22 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index d3ee068eba..1f2ca92bdd 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -848,6 +848,50 @@ ConvertDevicePathToShortText( } =20 /** + Function to dump protocol information. + + This will allocate the return buffer from boot services pool. + + @param[in] TheHandle The handle that has the protocol installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + @param[in] Protocol The protocol is needed to dump. + + @retval A pointer to a string containing the information. +**/ +STATIC CHAR16* +EFIAPI +DevicePathProtocolDumpInformationEx ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose, + IN EFI_GUID *Protocol +) +{ + EFI_DEVICE_PATH_PROTOCOL *DevPath; + CHAR16 *DevPathStr; + CHAR16 *DevPathStrTemp; + UINTN Size; + EFI_STATUS Status; + DevPathStr =3D NULL; + DevPathStrTemp =3D NULL; + Status =3D gBS->OpenProtocol(TheHandle, Protocol, (VOID**)&DevPath, gIma= geHandle, NULL, EFI_OPEN_PROTOCOL_GET_PROTOCOL); + if (!EFI_ERROR(Status)) { + DevPathStr =3D ConvertDevicePathToShortText (DevPath, Verbose, 30); + if (Verbose) { + Size =3D StrSize(DevPathStr) + sizeof(CHAR16) * 2; + DevPathStrTemp =3D AllocateZeroPool (Size); + if (DevPathStrTemp !=3D NULL) { + StrnCatS (DevPathStrTemp, Size/sizeof(CHAR16), L" ", 2); + StrnCatS (DevPathStrTemp, Size/sizeof(CHAR16), DevPathStr, StrLen = (DevPathStr)); + } + FreePool (DevPathStr); + DevPathStr =3D DevPathStrTemp; + } + gBS->CloseProtocol(TheHandle, Protocol, gImageHandle, NULL); + } + return DevPathStr; +} + +/** Function to dump information about DevicePath protocol. =20 This will allocate the return buffer from boot services pool. @@ -864,17 +908,7 @@ DevicePathProtocolDumpInformation( IN CONST BOOLEAN Verbose ) { - EFI_DEVICE_PATH_PROTOCOL *DevPath; - CHAR16 *Temp; - EFI_STATUS Status; - Temp =3D NULL; - - Status =3D gBS->OpenProtocol(TheHandle, &gEfiDevicePathProtocolGuid, (VO= ID**)&DevPath, gImageHandle, NULL, EFI_OPEN_PROTOCOL_GET_PROTOCOL); - if (!EFI_ERROR(Status)) { - Temp =3D ConvertDevicePathToShortText (DevPath, Verbose, 30); - gBS->CloseProtocol(TheHandle, &gEfiDevicePathProtocolGuid, gImageHandl= e, NULL); - } - return (Temp); + return DevicePathProtocolDumpInformationEx (TheHandle, Verbose, &gEfiDev= icePathProtocolGuid); } =20 /** @@ -894,17 +928,7 @@ LoadedImageDevicePathProtocolDumpInformation( IN CONST BOOLEAN Verbose ) { - EFI_DEVICE_PATH_PROTOCOL *DevPath; - CHAR16 *Temp; - EFI_STATUS Status; - Temp =3D NULL; - - Status =3D gBS->OpenProtocol(TheHandle, &gEfiLoadedImageDevicePathProtoc= olGuid, (VOID**)&DevPath, gImageHandle, NULL, EFI_OPEN_PROTOCOL_GET_PROTOCO= L); - if (!EFI_ERROR(Status)) { - Temp =3D ConvertDevicePathToShortText (DevPath, Verbose, 30); - gBS->CloseProtocol(TheHandle, &gEfiDevicePathProtocolGuid, gImageHandl= e, NULL); - } - return (Temp); + return DevicePathProtocolDumpInformationEx (TheHandle, Verbose, &gEfiLoa= dedImageDevicePathProtocolGuid); } =20 /** --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059433261994.6270335114247; Thu, 21 Sep 2017 22:50:33 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 7ACB82095E4F3; Thu, 21 Sep 2017 22:47:17 -0700 (PDT) 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 266D22095E4E4 for ; Thu, 21 Sep 2017 22:47:15 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:22 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:21 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738608" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:06 +0800 Message-Id: <20170922055014.27288-7-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 06/14] ShellPkg/dh: Modify the dump of LoadedImage protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 24 ++++++++++++++----= ---- .../UefiHandleParsingLib/UefiHandleParsingLib.h | 3 ++- .../UefiHandleParsingLib/UefiHandleParsingLib.inf | 3 ++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 3 ++- 4 files changed, 21 insertions(+), 12 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index 1f2ca92bdd..b9eb564dd0 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -232,14 +232,11 @@ LoadedImageProtocolDumpInformation( CHAR16 *RetVal; CHAR16 *Temp; CHAR16 *FileName; + CHAR8 *PdbFileName; CHAR16 *FilePath; CHAR16 *CodeType; CHAR16 *DataType; =20 - if (!Verbose) { - return (CatSPrint(NULL, L"LoadedImage")); - } - Status =3D gBS->OpenProtocol ( TheHandle, &gEfiLoadedImageProtocolGuid, @@ -253,10 +250,20 @@ LoadedImageProtocolDumpInformation( return NULL; } =20 - HandleParsingHiiInit(); - FileName =3D FindLoadedImageFileName(LoadedImage); + FilePath =3D ConvertDevicePathToText(LoadedImage->FilePath, TRUE, TRUE); + if (!Verbose) { + if (FileName =3D=3D NULL) { + FileName =3D FilePath; + } else { + SHELL_FREE_NON_NULL(FilePath); + } + RetVal =3D CatSPrint(NULL, FileName); + SHELL_FREE_NON_NULL(FileName); + return RetVal; + } =20 + HandleParsingHiiInit(); RetVal =3D NULL; if (FileName !=3D NULL) { Temp =3D HiiGetString(mHandleParsingHiiHandle, STRING_TOKEN(STR_LI_DUM= P_NAME), NULL); @@ -273,9 +280,7 @@ LoadedImageProtocolDumpInformation( if (Temp =3D=3D NULL) { return NULL; } - - FilePath =3D ConvertDevicePathToText(LoadedImage->FilePath, TRUE, TRUE); - + PdbFileName =3D PeCoffLoaderGetPdbPointer (LoadedImage->ImageBase); DataType =3D ConvertMemoryType(LoadedImage->ImageDataType); CodeType =3D ConvertMemoryType(LoadedImage->ImageCodeType); =20 @@ -287,6 +292,7 @@ LoadedImageProtocolDumpInformation( LoadedImage->SystemTable, LoadedImage->DeviceHandle, FilePath, + PdbFileName, LoadedImage->LoadOptionsSize, LoadedImage->LoadOptions, LoadedImage->ImageBase, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h index ada2b4aa38..cf849658aa 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.h @@ -1,7 +1,7 @@ /** @file Provides interface to advanced shell functionality for parsing both hand= le and protocol database. =20 - Copyright (c) 2011 - 2016, Intel Corporation. All rights reserved.
+ Copyright (c) 2011 - 2017, Intel Corporation. All rights reserved.
(C) Copyright 2016 Hewlett Packard Enterprise Development LP
(C) Copyright 2013-2016 Hewlett-Packard Development Company, L.P.
This program and the accompanying materials @@ -153,6 +153,7 @@ #include #include #include +#include =20 #define EFI_FIRMWARE_IMAGE_DESCRIPTOR_VERSION_V1 1 #define EFI_FIRMWARE_IMAGE_DESCRIPTOR_VERSION_V2 2 diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf index 3bd4dbe423..4c1c3d3846 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.inf @@ -1,6 +1,6 @@ ## @file # Provides interface to advanced shell functionality for parsing both han= dle and protocol database. -# Copyright (c) 2010 - 2015, Intel Corporation. All rights reserved.
+# Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
# (C) Copyright 2013-2015 Hewlett-Packard Development Company, L.P.
# (C) Copyright 2015 Hewlett Packard Enterprise Development LP
# @@ -50,6 +50,7 @@ [LibraryClasses] UefiLib HiiLib SortLib + PeCoffGetEntryPointLib =20 [Protocols] gEfiSimpleFileSystemProtocolGuid ## SOMETIMES_CON= SUMES diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index e07c9a1670..8541399b68 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -355,13 +355,14 @@ " SystemTable...: %%= H%x%%N\r\n" " DeviceHandle..: %%= H%x%%N\r\n" " FilePath......: %%= H%s%%N\r\n" + " PdbFileName...: %%= H%a%%N\r\n" " OptionsSize...: %%= H%x%%N\r\n" " LoadOptions...: %%= H%x%%N\r\n" " ImageBase.....: %%= H%x%%N\r\n" " ImageSize.....: %%= H%Lx%%N\r\n" " CodeType......: %%= H%s%%N\r\n" " DataType......: %%= H%s%%N\r\n" - " Unload........: %%= H%x%%N\r\n" + " Unload........: %%= H%x%%N" =20 #string STR_GOP_DUMP_MAIN #language en-US " Max Mode..........= ..: %%H0x%08x%%N\r\n" " Current Mode......= ..: %%H0x%08x%%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059436142855.4679493214678; Thu, 21 Sep 2017 22:50:36 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id B58B32095E4F6; Thu, 21 Sep 2017 22:47:17 -0700 (PDT) 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 195A42095E4E2 for ; Thu, 21 Sep 2017 22:47:16 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:23 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:22 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738612" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:07 +0800 Message-Id: <20170922055014.27288-8-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 07/14] ShellPkg/dh: Modify the dump of BusSpecificDriverOverride protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 81 ++++++++++++++++++= +++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 2 +- 2 files changed, 81 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index b9eb564dd0..ce2b49b5a2 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -938,6 +938,85 @@ LoadedImageDevicePathProtocolDumpInformation( } =20 /** + Function to dump information about BusSpecificDriverOverride protocol. + + This will allocate the return buffer from boot services pool. + + @param[in] TheHandle The handle that has the protocol installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + + @retval A pointer to a string containing the information. +**/ +CHAR16* +EFIAPI +BusSpecificDriverOverrideProtocolDumpInformation ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose + ) +{ + EFI_STATUS Status; + CHAR16 *GetString; + CHAR16 *RetVal; + CHAR16 *TempRetVal; + EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL *BusSpecificDriverOverride; + EFI_LOADED_IMAGE_PROTOCOL *LoadedImage; + EFI_HANDLE ImageHandle; + UINTN Size; + + if (!Verbose) { + return NULL; + } + Size =3D 0; + GetString =3D NULL; + RetVal =3D NULL; + TempRetVal =3D NULL; + ImageHandle =3D 0; + + Status =3D gBS->OpenProtocol ( + TheHandle, + &gEfiBusSpecificDriverOverrideProtocolGuid, + (VOID**)&BusSpecificDriverOverride, + gImageHandle, + NULL, + EFI_OPEN_PROTOCOL_GET_PROTOCOL + ); + if (EFI_ERROR (Status)) { + return NULL; + } + HandleParsingHiiInit (); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_BS= DO_DUMP_MAIN), NULL); + if (GetString =3D=3D NULL) { + return NULL; + } + do { + Status =3D BusSpecificDriverOverride->GetDriver ( + BusSpecificDriverOverride, + &ImageHandle + ); + if (!EFI_ERROR (Status)) { + Status =3D gBS->HandleProtocol ( + ImageHandle, + &gEfiLoadedImageProtocolGuid, + (VOID **) &LoadedImage + ); + if(!EFI_ERROR (Status)) { + TempRetVal =3D CatSPrint ( + TempRetVal, + GetString, + ConvertHandleToHandleIndex (ImageHandle), + ConvertDevicePathToText (LoadedImage->FilePath, TRU= E, TRUE) + ); + StrnCatGrow (&RetVal, &Size, TempRetVal, 0); + SHELL_FREE_NON_NULL (TempRetVal); + } + } + } while (!EFI_ERROR (Status)); + + SHELL_FREE_NON_NULL (GetString); + return RetVal; +} + +/** Function to dump information about EfiAdapterInformation Protocol. =20 @param[in] TheHandle The handle that has the protocol installed. @@ -1623,7 +1702,7 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { {STRING_TOKEN(STR_DEVICE_PATH_VTUTF8), &gEfiVTUTF8Guid, = NULL}, {STRING_TOKEN(STR_DRIVER_BINDING), &gEfiDriverBindingProtocolGuid= , NULL}, {STRING_TOKEN(STR_PLATFORM_OVERRIDE), &gEfiPlatformDriverOverridePro= tocolGuid, NULL}, - {STRING_TOKEN(STR_BUS_OVERRIDE), &gEfiBusSpecificDriverOverride= ProtocolGuid, NULL}, + {STRING_TOKEN(STR_BUS_OVERRIDE), &gEfiBusSpecificDriverOverride= ProtocolGuid, BusSpecificDriverOverrideProtocolDumpInformation}, {STRING_TOKEN(STR_DRIVER_DIAG), &gEfiDriverDiagnosticsProtocol= Guid, NULL}, {STRING_TOKEN(STR_DRIVER_DIAG2), &gEfiDriverDiagnostics2Protoco= lGuid, NULL}, {STRING_TOKEN(STR_DRIVER_CN), &gEfiComponentNameProtocolGuid= , NULL}, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 8541399b68..3f9fc9cbac 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -384,7 +384,7 @@ #string STR_GOP_RES_LIST_ENTRY #language en-US " Resolution[%%H%d= %%N]:\r\n" " Res Hor.......= ..: %%H0x%08x%%N\r\n" " Res Ver.......= ..: %%H0x%08x%%N\r\n" - +#string STR_BSDO_DUMP_MAIN #language en-US " Drv[%02x] File:%%H= %s%%N" #string STR_EDID_DISCOVERED_MAIN #language en-US " EDID Discovered Si= ze : %%H0x%08x%%N\r\n" #string STR_EDID_DISCOVERED_DATA #language en-US " EDID Discovered Da= ta :\r\n" #string STR_EDID_ACTIVE_MAIN #language en-US " EDID Active Size := %%H0x%08x%%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059438654448.83216523274575; Thu, 21 Sep 2017 22:50:38 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id EEA712095E4F9; Thu, 21 Sep 2017 22:47:17 -0700 (PDT) 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 F412321ECCB2A for ; Thu, 21 Sep 2017 22:47:16 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:24 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:23 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738617" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:08 +0800 Message-Id: <20170922055014.27288-9-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 08/14] ShellPkg/dh: Modify the dump of BlockIo protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 80 ++++++++++++++++++= +++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 1 + 2 files changed, 80 insertions(+), 1 deletion(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index ce2b49b5a2..fb67197171 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -1017,6 +1017,84 @@ BusSpecificDriverOverrideProtocolDumpInformation ( } =20 /** + Function to dump information about BlockIo protocol. + + This will allocate the return buffer from boot services pool. + + @param[in] TheHandle The handle that has the protocol installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + + @retval A pointer to a string containing the information. +**/ +CHAR16* +EFIAPI +BlockIoProtocolDumpInformation ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose + ) +{ + EFI_STATUS Status; + EFI_BLOCK_IO_PROTOCOL *BlockIo; + EFI_BLOCK_IO_MEDIA *BlockMedia; + CHAR16 *GetString; + CHAR16 *RetVal; + + if (!Verbose) { + return NULL; + } + GetString =3D NULL; + RetVal =3D NULL; + + Status =3D gBS->OpenProtocol ( + TheHandle, + &gEfiBlockIoProtocolGuid, + (VOID**)&BlockIo, + gImageHandle, + NULL, + EFI_OPEN_PROTOCOL_GET_PROTOCOL + ); + if (EFI_ERROR (Status)) { + return NULL; + } + BlockMedia =3D BlockIo->Media; + // + // Per spec: + // The function (ReadBlocks) must return EFI_NO_MEDIA or + // EFI_MEDIA_CHANGED even if LBA, BufferSize, or Buffer are invalid so= the caller can probe + // for changes in media state. + // + BlockIo->ReadBlocks ( + BlockIo, + BlockIo->Media->MediaId, + 0, + 0, + NULL + ); + + HandleParsingHiiInit (); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_BL= OCKIO_INFO), NULL); + if (GetString =3D=3D NULL) { + return NULL; + } + RetVal =3D CatSPrint ( + RetVal, + GetString, + BlockMedia->RemovableMedia ? L"Removable " : L"Fixed ", + BlockMedia->MediaPresent ? L"" : L"not-present ", + BlockMedia->MediaId, + BlockMedia->BlockSize, + BlockMedia->LastBlock, + MultU64x32 (BlockMedia->LastBlock + 1, BlockMedia->BlockSize), + BlockMedia->LogicalPartition ? L"partition" : L"raw", + BlockMedia->ReadOnly ? L"ro" : L"rw", + BlockMedia->WriteCaching ? L"cached" : L"!cached" + ); + + SHELL_FREE_NON_NULL (GetString); + return RetVal; +} + +/** Function to dump information about EfiAdapterInformation Protocol. =20 @param[in] TheHandle The handle that has the protocol installed. @@ -1727,7 +1805,7 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { {STRING_TOKEN(STR_SIMPLE_FILE_SYS), &gEfiSimpleFileSystemProtocolG= uid, NULL}, {STRING_TOKEN(STR_TAPE_IO), &gEfiTapeIoProtocolGuid, = NULL}, {STRING_TOKEN(STR_DISK_IO), &gEfiDiskIoProtocolGuid, = NULL}, - {STRING_TOKEN(STR_BLK_IO), &gEfiBlockIoProtocolGuid, = NULL}, + {STRING_TOKEN(STR_BLK_IO), &gEfiBlockIoProtocolGuid, = BlockIoProtocolDumpInformation}, {STRING_TOKEN(STR_UC), &gEfiUnicodeCollationProtocolG= uid, NULL}, {STRING_TOKEN(STR_UC2), &gEfiUnicodeCollation2Protocol= Guid, NULL}, {STRING_TOKEN(STR_PCIRB_IO), &gEfiPciRootBridgeIoProtocolGu= id, PciRootBridgeIoDumpInformation}, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 3f9fc9cbac..eeb6aded6f 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -335,6 +335,7 @@ =20 #string STR_IDE_CONT_INIT #language en-US "IdeControllerInit" #string STR_DISK_INFO #language en-US "DiskInfo" +#string STR_BLOCKIO_INFO #language en-US " %s%sMId:%%H%x%%N bsiz= e %%H%x%%N, lblock %lx (%,ld), %s %s %s" =20 #string STR_PCIRB_DUMP_PH #language en-US " ParentHandle..: %H= %x%N\r\n" #string STR_PCIRB_DUMP_SEG #language en-US " Segment #.....: %H= %x%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059441721936.6101536255401; Thu, 21 Sep 2017 22:50:41 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 36C232095E4FD; Thu, 21 Sep 2017 22:47:23 -0700 (PDT) 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 DF3A52095E4F1 for ; Thu, 21 Sep 2017 22:47:17 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:25 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:24 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738623" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:09 +0800 Message-Id: <20170922055014.27288-10-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 09/14] ShellPkg/dh: Modify the dump of DebugSupport protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 67 ++++++++++++++++++= +++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 2 + 2 files changed, 68 insertions(+), 1 deletion(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index fb67197171..1c62415e86 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -1095,6 +1095,71 @@ BlockIoProtocolDumpInformation ( } =20 /** + Function to dump information about DebugSupport Protocol. + + @param[in] TheHandle The handle that has the protocol installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + + @retval A pointer to a string containing the information. +**/ +CHAR16* +EFIAPI +DebugSupportProtocolDumpInformation ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose + ) +{ + EFI_STATUS Status; + EFI_DEBUG_SUPPORT_PROTOCOL *DebugSupport; + CHAR16 *GetString; + CHAR16 *RetVal; + + if (!Verbose) { + return NULL; + } + GetString =3D NULL; + RetVal =3D NULL; + Status =3D gBS->OpenProtocol ( + TheHandle, + &gEfiDebugSupportProtocolGuid, + (VOID**)&DebugSupport, + gImageHandle, + NULL, + EFI_OPEN_PROTOCOL_GET_PROTOCOL + ); + if (EFI_ERROR (Status)) { + return NULL; + } + HandleParsingHiiInit (); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_DE= BUGSUPPORT_INFO), NULL); + if (GetString =3D=3D NULL) { + return NULL; + } + // + // Dump Debug support info + // + switch (DebugSupport->Isa) { + case (IsaIa32): + RetVal =3D CatSPrint (RetVal, GetString, L"IA-32"); + break; + case (IsaIpf): + RetVal =3D CatSPrint (RetVal, GetString, L"IPF"); + break; + case (IsaEbc): + RetVal =3D CatSPrint (RetVal, GetString, L"EBC"); + break; + default: + SHELL_FREE_NON_NULL (GetString); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_= DEBUGSUPPORT_UNKNOWN), NULL); + RetVal =3D GetString !=3D NULL ? CatSPrint (RetVal, GetString, DebugSu= pport->Isa) : NULL; + break; + } + + SHELL_FREE_NON_NULL (GetString); + return RetVal; +} + +/** Function to dump information about EfiAdapterInformation Protocol. =20 @param[in] TheHandle The handle that has the protocol installed. @@ -1817,7 +1882,7 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { {STRING_TOKEN(STR_USB_IO), &gEfiUsbIoProtocolGuid, = NULL}, {STRING_TOKEN(STR_USB_HC), &gEfiUsbHcProtocolGuid, = NULL}, {STRING_TOKEN(STR_USB_HC2), &gEfiUsb2HcProtocolGuid, = NULL}, - {STRING_TOKEN(STR_DEBUG_SUPPORT), &gEfiDebugSupportProtocolGuid,= NULL}, + {STRING_TOKEN(STR_DEBUG_SUPPORT), &gEfiDebugSupportProtocolGuid,= DebugSupportProtocolDumpInformation}, {STRING_TOKEN(STR_DEBUG_PORT), &gEfiDebugPortProtocolGuid, = NULL}, {STRING_TOKEN(STR_DECOMPRESS), &gEfiDecompressProtocolGuid, = NULL}, {STRING_TOKEN(STR_ACPI_TABLE), &gEfiAcpiTableProtocolGuid, = NULL}, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index eeb6aded6f..ca5e362bc7 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -336,6 +336,8 @@ #string STR_IDE_CONT_INIT #language en-US "IdeControllerInit" #string STR_DISK_INFO #language en-US "DiskInfo" #string STR_BLOCKIO_INFO #language en-US " %s%sMId:%%H%x%%N bsiz= e %%H%x%%N, lblock %lx (%,ld), %s %s %s" +#string STR_DEBUGSUPPORT_INFO #language en-US " Isa =3D %s" +#string STR_DEBUGSUPPORT_UNKNOWN #language en-US " Unknown (%%H%s%%N)" =20 #string STR_PCIRB_DUMP_PH #language en-US " ParentHandle..: %H= %x%N\r\n" #string STR_PCIRB_DUMP_SEG #language en-US " Segment #.....: %H= %x%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059444391432.3753904741146; Thu, 21 Sep 2017 22:50:44 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 7109F2095E500; Thu, 21 Sep 2017 22:47:23 -0700 (PDT) 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 CDD9721ECCB3B for ; Thu, 21 Sep 2017 22:47:18 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:26 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:25 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738629" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:10 +0800 Message-Id: <20170922055014.27288-11-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 10/14] ShellPkg/dh: Modify the dump of GraphicsOutput protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 36 +++++++++++-------= ---- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index ca5e362bc7..4b0c67b42a 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -367,26 +367,26 @@ " DataType......: %%= H%s%%N\r\n" " Unload........: %%= H%x%%N" =20 -#string STR_GOP_DUMP_MAIN #language en-US " Max Mode..........= ..: %%H0x%08x%%N\r\n" - " Current Mode......= ..: %%H0x%08x%%N\r\n" - " Frame Buffer Base.= ..: %%H0x%L016x%%N\r\n" - " Frame Buffer Size.= ..: %%H0x%L016x%%N\r\n" - " Mode Info Size....= ..: %%H0x%L016x%%N\r\n" +#string STR_GOP_DUMP_MAIN #language en-US " Max Mode..........= ....: %%H0x%08x%%N\r\n" + " Current Mode......= ....: %%H0x%08x%%N\r\n" + " Frame Buffer Base.= ....: %%H0x%L016x%%N\r\n" + " Frame Buffer Size.= ....: %%H0x%L016x%%N\r\n" + " Mode Info Size....= ....: %%H0x%L016x%%N\r\n" " Information\r\n" - " Version.........= ..: %%H0x%08x%%N\r\n" - " Res Hor.........= ..: %%H0x%08x%%N\r\n" - " Res Ver.........= ..: %%H0x%08x%%N\r\n" - " Pixel Format....= ..: %%H%s%%N\r\n" - " Pixels / Scan Li= ne: %%H0x%08x%%N\r\n" + " Version.........= ....: %%H0x%08x%%N\r\n" + " HorizontalResolu= tion: %%H%d%%N\r\n" + " VerticalResoluti= on..: %%H%d%%N\r\n" + " Pixel Format....= ....: %%H%s%%N\r\n" + " Pixels / Scan Li= ne..: %%H%d%%N\r\n" " Pixel Info\r\n" - " RedMask.......= ..: %%H0x%08x%%N\r\n" - " GreenMask.....= ..: %%H0x%08x%%N\r\n" - " BlueMask......= ..: %%H0x%08x%%N\r\n" - -#string STR_GOP_RES_LIST_MAIN #language en-US " Supported Resoluti= on List\r\n" -#string STR_GOP_RES_LIST_ENTRY #language en-US " Resolution[%%H%d= %%N]:\r\n" - " Res Hor.......= ..: %%H0x%08x%%N\r\n" - " Res Ver.......= ..: %%H0x%08x%%N\r\n" + " RedMask.......= ....: %%H0x%08x%%N\r\n" + " GreenMask.....= ....: %%H0x%08x%%N\r\n" + " BlueMask......= ....: %%H0x%08x%%N\r\n" + +#string STR_GOP_RES_LIST_MAIN #language en-US " Supported Resoluti= on List" +#string STR_GOP_RES_LIST_ENTRY #language en-US "\r\n Resolution[%= %H%d%%N]:\r\n" + " Horizontal....= ....: %%H%d%%N\r\n" + " Vertical......= ....: %%H%d%%N" #string STR_BSDO_DUMP_MAIN #language en-US " Drv[%02x] File:%%H= %s%%N" #string STR_EDID_DISCOVERED_MAIN #language en-US " EDID Discovered Si= ze : %%H0x%08x%%N\r\n" #string STR_EDID_DISCOVERED_DATA #language en-US " EDID Discovered Da= ta :\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:53 2024 Delivered-To: importer@patchew.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; 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 1506059447310626.8432577648693; Thu, 21 Sep 2017 22:50:47 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id AA4202095E503; Thu, 21 Sep 2017 22:47:23 -0700 (PDT) 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 CC2FE2095E4E2 for ; Thu, 21 Sep 2017 22:47:19 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:27 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:26 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738632" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:11 +0800 Message-Id: <20170922055014.27288-12-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 11/14] ShellPkg/dh: Modify the dump of PciIo protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 87 ++++++++++++++++++= +++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 11 ++- 2 files changed, 96 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index 1c62415e86..e5b4bea8f6 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -16,6 +16,7 @@ =20 #include "UefiHandleParsingLib.h" #include "IndustryStandard/Acpi10.h" +#include "IndustryStandard/Pci.h" #include #include =20 @@ -1160,6 +1161,90 @@ DebugSupportProtocolDumpInformation ( } =20 /** + Function to dump information about PciIoProtocol. + + This will allocate the return buffer from boot services pool. + + @param[in] TheHandle The handle that has PciRootBridgeIo installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + + @retval A poitner to a string containing the information. +**/ +CHAR16* +EFIAPI +PciIoProtocolDumpInformation ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose + ) +{ + EFI_STATUS Status; + EFI_PCI_IO_PROTOCOL *PciIo; + PCI_TYPE00 Pci; + UINTN Segment; + UINTN Bus; + UINTN Device; + UINTN Function; + UINTN Index; + CHAR16 *GetString; + CHAR16 *TempRetVal; + CHAR16 *RetVal; + + if (!Verbose) { + return (NULL); + } + RetVal =3D NULL; + GetString =3D NULL; + TempRetVal =3D NULL; + Status =3D gBS->OpenProtocol ( + TheHandle, + &gEfiPciIoProtocolGuid, + (VOID**)&PciIo, + gImageHandle, + NULL, + EFI_OPEN_PROTOCOL_GET_PROTOCOL + ); + + if (EFI_ERROR(Status)) { + return NULL; + } + PciIo->Pci.Read (PciIo, EfiPciIoWidthUint8, 0, sizeof (Pci), &Pci); + PciIo->GetLocation (PciIo, &Segment, &Bus, &Device, &Function); + HandleParsingHiiInit (); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_PC= IIO_DUMP_MAIN), NULL); + if (GetString =3D=3D NULL) { + return NULL; + } + RetVal =3D CatSPrint ( + NULL, + GetString, + Segment, + Bus, + Device, + Function, + PciIo->RomSize, + PciIo->RomImage, + Pci.Hdr.VendorId, + Pci.Hdr.DeviceId, + Pci.Hdr.ClassCode[0], + Pci.Hdr.ClassCode[1], + Pci.Hdr.ClassCode[2] + ); + for (Index =3D 0; Index < sizeof (Pci); Index ++) { + if ((Index % 0x10) =3D=3D 0) { + TempRetVal =3D CatSPrint (RetVal, L"\r\n %02x", *((UINT8 *) (&= Pci) + Index)); + } else { + TempRetVal =3D CatSPrint (RetVal, L"%02x", *((UINT8 *) (&Pci) + Inde= x)); + } + FreePool (RetVal); + RetVal =3D TempRetVal; + TempRetVal =3D NULL; + } + + FreePool(GetString); + return RetVal; +} + +/** Function to dump information about EfiAdapterInformation Protocol. =20 @param[in] TheHandle The handle that has the protocol installed. @@ -1874,7 +1959,7 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { {STRING_TOKEN(STR_UC), &gEfiUnicodeCollationProtocolG= uid, NULL}, {STRING_TOKEN(STR_UC2), &gEfiUnicodeCollation2Protocol= Guid, NULL}, {STRING_TOKEN(STR_PCIRB_IO), &gEfiPciRootBridgeIoProtocolGu= id, PciRootBridgeIoDumpInformation}, - {STRING_TOKEN(STR_PCI_IO), &gEfiPciIoProtocolGuid, = NULL}, + {STRING_TOKEN(STR_PCI_IO), &gEfiPciIoProtocolGuid, = PciIoProtocolDumpInformation}, {STRING_TOKEN(STR_SCSI_PT), &gEfiScsiPassThruProtocolGuid,= NULL}, {STRING_TOKEN(STR_SCSI_IO), &gEfiScsiIoProtocolGuid, = NULL}, {STRING_TOKEN(STR_SCSI_PT_EXT), &gEfiExtScsiPassThruProtocolGu= id, NULL}, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 4b0c67b42a..59409d9ca0 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -348,7 +348,16 @@ #string STR_PCIRB_DUMP_IO #language en-US " IO : " #string STR_PCIRB_DUMP_TITLE #language en-US " Type Flag Base = Limit Gran\r\n" " =3D=3D=3D=3D =3D= =3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D\r\n" - +#string STR_PCIIO_DUMP_MAIN #language en-US " Segment #.....: %0= 2x\r\n" + " Bus #.........: %0= 2x\r\n" + " Device #......: %0= 2x\r\n" + " Function #....: %0= 2x\r\n" + " ROM Size......: %l= x\r\n" + " ROM Location..: %0= 8x\r\n" + " Vendor ID.....: %0= 4x\r\n" + " Device ID.....: %0= 4x\r\n" + " Class Code....: %0= 2x %02x %02x\r\n" + " Configuration Head= er :" =20 =20 #string STR_LI_DUMP_NAME #language en-US " Name..........: %%= H%s%%N\r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:54 2024 Delivered-To: importer@patchew.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; 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 1506059450197458.80189923320665; Thu, 21 Sep 2017 22:50:50 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id E97D32095E506; Thu, 21 Sep 2017 22:47:23 -0700 (PDT) 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 B57B32095E4E3 for ; Thu, 21 Sep 2017 22:47:20 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:28 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:27 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738635" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:12 +0800 Message-Id: <20170922055014.27288-13-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 12/14] ShellPkg/dh: Modify the dump of UsbIo protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 61 ++++++++++++++++++= +++- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 5 +- 2 files changed, 64 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index e5b4bea8f6..164caa9b91 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -1245,6 +1245,65 @@ PciIoProtocolDumpInformation ( } =20 /** + Function to dump information about UsbIoProtocol. + + This will allocate the return buffer from boot services pool. + + @param[in] TheHandle The handle that has PciRootBridgeIo installed. + @param[in] Verbose TRUE for additional information, FALSE otherwi= se. + + @retval A poitner to a string containing the information. +**/ +CHAR16* +EFIAPI +UsbIoProtocolDumpInformation ( + IN CONST EFI_HANDLE TheHandle, + IN CONST BOOLEAN Verbose + ) +{ + EFI_STATUS Status; + EFI_USB_IO_PROTOCOL *UsbIo; + EFI_USB_INTERFACE_DESCRIPTOR InterfaceDesc; + CHAR16 *GetString; + CHAR16 *RetVal; + + if (!Verbose) { + return (NULL); + } + RetVal =3D NULL; + GetString =3D NULL; + Status =3D gBS->OpenProtocol ( + TheHandle, + &gEfiUsbIoProtocolGuid, + (VOID**)&UsbIo, + gImageHandle, + NULL, + EFI_OPEN_PROTOCOL_GET_PROTOCOL + ); + + if (EFI_ERROR(Status)) { + return NULL; + } + UsbIo->UsbGetInterfaceDescriptor (UsbIo, &InterfaceDesc); + HandleParsingHiiInit (); + GetString =3D HiiGetString (mHandleParsingHiiHandle, STRING_TOKEN(STR_US= BIO_DUMP_MAIN), NULL); + if (GetString =3D=3D NULL) { + return NULL; + } + RetVal =3D CatSPrint ( + NULL, + GetString, + InterfaceDesc.InterfaceNumber, + InterfaceDesc.InterfaceClass, + InterfaceDesc.InterfaceSubClass, + InterfaceDesc.InterfaceProtocol + ); + + FreePool (GetString); + return RetVal; +} + +/** Function to dump information about EfiAdapterInformation Protocol. =20 @param[in] TheHandle The handle that has the protocol installed. @@ -1964,7 +2023,7 @@ STATIC CONST GUID_INFO_BLOCK mGuidStringList[] =3D { {STRING_TOKEN(STR_SCSI_IO), &gEfiScsiIoProtocolGuid, = NULL}, {STRING_TOKEN(STR_SCSI_PT_EXT), &gEfiExtScsiPassThruProtocolGu= id, NULL}, {STRING_TOKEN(STR_ISCSI), &gEfiIScsiInitiatorNameProtoco= lGuid, NULL}, - {STRING_TOKEN(STR_USB_IO), &gEfiUsbIoProtocolGuid, = NULL}, + {STRING_TOKEN(STR_USB_IO), &gEfiUsbIoProtocolGuid, = UsbIoProtocolDumpInformation}, {STRING_TOKEN(STR_USB_HC), &gEfiUsbHcProtocolGuid, = NULL}, {STRING_TOKEN(STR_USB_HC2), &gEfiUsb2HcProtocolGuid, = NULL}, {STRING_TOKEN(STR_DEBUG_SUPPORT), &gEfiDebugSupportProtocolGuid,= DebugSupportProtocolDumpInformation}, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 59409d9ca0..98299cd1d0 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -358,7 +358,10 @@ " Device ID.....: %0= 4x\r\n" " Class Code....: %0= 2x %02x %02x\r\n" " Configuration Head= er :" - +#string STR_USBIO_DUMP_MAIN #language en-US " Interface Number #= .....: %02x\r\n" + " Interface Class #.= .....: %02x\r\n" + " Interface Subclass= #...: %02x\r\n" + " Interface Protocol= #...: %02x" =20 #string STR_LI_DUMP_NAME #language en-US " Name..........: %%= H%s%%N\r\n" =20 --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:54 2024 Delivered-To: importer@patchew.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; 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 1506059453221137.84461445360637; Thu, 21 Sep 2017 22:50:53 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 311092095E507; Thu, 21 Sep 2017 22:47:24 -0700 (PDT) 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 9D41B2095E4E2 for ; Thu, 21 Sep 2017 22:47:21 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:29 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:28 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738638" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:13 +0800 Message-Id: <20170922055014.27288-14-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 13/14] ShellPkg/dh: Modify the dump of UsbIo protocol 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: , Cc: Jaben Carsey , Huajing Li 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" From: Huajing Li Reviewed-by: Ruiyu Ni Cc: Jaben Carsey Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Huajing Li Reviewed-by: Jaben Carsey --- ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 98299cd1d0..5d8a0d1bb9 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -179,8 +179,8 @@ #string STR_HII #language en-US "HII" #string STR_HII_FORM_CALLBACK #language en-US "HIICallback" =20 -#string STR_TXT_OUT_DUMP_HEADER #language en-US " Address: %%H%X%%N Att= rib %02x\r\n" -#string STR_TXT_OUT_DUMP_LINE #language en-US " %c mode %d: Col %d R= ow %d\r\n" +#string STR_TXT_OUT_DUMP_HEADER #language en-US " Address: %%H%X%%N Att= rib %02x" +#string STR_TXT_OUT_DUMP_LINE #language en-US "\r\n %c mode %d: Col = %d Row %d" =20 #string STR_DRIVER_FAM_OVERRIDE #language en-US "DriverFamilyOverride" #string STR_PCD #language en-US "Pcd" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Thu Dec 26 00:25:54 2024 Delivered-To: importer@patchew.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; 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 1506059456395882.6105439960807; Thu, 21 Sep 2017 22:50:56 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 6C2222095E50A; Thu, 21 Sep 2017 22:47:24 -0700 (PDT) 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 A339F2095E4E2 for ; Thu, 21 Sep 2017 22:47:22 -0700 (PDT) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 21 Sep 2017 22:50:30 -0700 Received: from ray-dev.ccr.corp.intel.com ([10.239.9.7]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2017 22:50:29 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,427,1500966000"; d="scan'208";a="154738641" From: Ruiyu Ni To: edk2-devel@lists.01.org Date: Fri, 22 Sep 2017 13:50:14 +0800 Message-Id: <20170922055014.27288-15-ruiyu.ni@intel.com> X-Mailer: git-send-email 2.12.2.windows.2 In-Reply-To: <20170922055014.27288-1-ruiyu.ni@intel.com> References: <20170922055014.27288-1-ruiyu.ni@intel.com> Subject: [edk2] [PATCH 14/14] ShellPkg/dh: Refine the dump output 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: , Cc: Jaben Carsey 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" The patch doesn't change any real functionality. Only the indent width and EOL are changed. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni Cc: Jaben Carsey Reviewed-by: Jaben Carsey --- .../UefiHandleParsingLib/UefiHandleParsingLib.c | 8 +- .../UefiHandleParsingLib/UefiHandleParsingLib.uni | 129 +++++++++++------= ---- 2 files changed, 69 insertions(+), 68 deletions(-) diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c b= /ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c index 164caa9b91..d12466c7b0 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.c @@ -497,7 +497,7 @@ EdidDiscoveredProtocolDumpInformation ( SHELL_FREE_NON_NULL (RetVal); RetVal =3D TempRetVal; =20 - TempRetVal =3D CatSDumpHex (RetVal, 7, 0, EdidDiscovered->SizeOfEdid, = EdidDiscovered->Edid); + TempRetVal =3D CatSDumpHex (RetVal, 4, 0, EdidDiscovered->SizeOfEdid, = EdidDiscovered->Edid); RetVal =3D TempRetVal; } return RetVal; @@ -561,7 +561,7 @@ EdidActiveProtocolDumpInformation ( SHELL_FREE_NON_NULL (RetVal); RetVal =3D TempRetVal; =20 - TempRetVal =3D CatSDumpHex (RetVal, 7, 0, EdidActive->SizeOfEdid, Edid= Active->Edid); + TempRetVal =3D CatSDumpHex (RetVal, 4, 0, EdidActive->SizeOfEdid, Edid= Active->Edid); RetVal =3D TempRetVal; } return RetVal; @@ -614,7 +614,7 @@ PciRootBridgeIoDumpInformation( if (Temp =3D=3D NULL) { return NULL; } - Temp2 =3D CatSPrint(L"\r\n", Temp, PciRootBridgeIo->ParentHandle); + Temp2 =3D CatSPrint(NULL, Temp, PciRootBridgeIo->ParentHandle); FreePool(Temp); RetVal =3D Temp2; Temp2 =3D NULL; @@ -692,7 +692,7 @@ PciRootBridgeIoDumpInformation( } =20 Temp2 =3D CatSPrint(RetVal, - L"%H%02x %016lx %016lx %02x%N\r\n", + L"\r\n%%H%02x %016lx %016lx %02x%%N", Configuration->SpecificFlag, Configuration->AddrRangeMin, Configuration->AddrRangeMax, diff --git a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni= b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni index 5d8a0d1bb9..f49ca94623 100644 --- a/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni +++ b/ShellPkg/Library/UefiHandleParsingLib/UefiHandleParsingLib.uni @@ -339,71 +339,72 @@ #string STR_DEBUGSUPPORT_INFO #language en-US " Isa =3D %s" #string STR_DEBUGSUPPORT_UNKNOWN #language en-US " Unknown (%%H%s%%N)" =20 -#string STR_PCIRB_DUMP_PH #language en-US " ParentHandle..: %H= %x%N\r\n" -#string STR_PCIRB_DUMP_SEG #language en-US " Segment #.....: %H= %x%N\r\n" -#string STR_PCIRB_DUMP_ATT #language en-US " Attributes....: %H= %x%N\r\n" -#string STR_PCIRB_DUMP_SUPPORTS #language en-US " Supports......: %H= %x%N\r\n" -#string STR_PCIRB_DUMP_BUS #language en-US " BUS : " -#string STR_PCIRB_DUMP_MEM #language en-US " MEM : " -#string STR_PCIRB_DUMP_IO #language en-US " IO : " -#string STR_PCIRB_DUMP_TITLE #language en-US " Type Flag Base = Limit Gran\r\n" - " =3D=3D=3D=3D =3D= =3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D\r\n" -#string STR_PCIIO_DUMP_MAIN #language en-US " Segment #.....: %0= 2x\r\n" - " Bus #.........: %0= 2x\r\n" - " Device #......: %0= 2x\r\n" - " Function #....: %0= 2x\r\n" - " ROM Size......: %l= x\r\n" - " ROM Location..: %0= 8x\r\n" - " Vendor ID.....: %0= 4x\r\n" - " Device ID.....: %0= 4x\r\n" - " Class Code....: %0= 2x %02x %02x\r\n" - " Configuration Head= er :" -#string STR_USBIO_DUMP_MAIN #language en-US " Interface Number #= .....: %02x\r\n" - " Interface Class #.= .....: %02x\r\n" - " Interface Subclass= #...: %02x\r\n" - " Interface Protocol= #...: %02x" - -#string STR_LI_DUMP_NAME #language en-US " Name..........: %%= H%s%%N\r\n" - -#string STR_LI_DUMP_MAIN #language en-US " Revision......: %%= H0x%08x%%N\r\n" - " ParentHandle..: %%= H%x%%N\r\n" - " SystemTable...: %%= H%x%%N\r\n" - " DeviceHandle..: %%= H%x%%N\r\n" - " FilePath......: %%= H%s%%N\r\n" - " PdbFileName...: %%= H%a%%N\r\n" - " OptionsSize...: %%= H%x%%N\r\n" - " LoadOptions...: %%= H%x%%N\r\n" - " ImageBase.....: %%= H%x%%N\r\n" - " ImageSize.....: %%= H%Lx%%N\r\n" - " CodeType......: %%= H%s%%N\r\n" - " DataType......: %%= H%s%%N\r\n" - " Unload........: %%= H%x%%N" - -#string STR_GOP_DUMP_MAIN #language en-US " Max Mode..........= ....: %%H0x%08x%%N\r\n" - " Current Mode......= ....: %%H0x%08x%%N\r\n" - " Frame Buffer Base.= ....: %%H0x%L016x%%N\r\n" - " Frame Buffer Size.= ....: %%H0x%L016x%%N\r\n" - " Mode Info Size....= ....: %%H0x%L016x%%N\r\n" - " Information\r\n" - " Version.........= ....: %%H0x%08x%%N\r\n" - " HorizontalResolu= tion: %%H%d%%N\r\n" - " VerticalResoluti= on..: %%H%d%%N\r\n" - " Pixel Format....= ....: %%H%s%%N\r\n" - " Pixels / Scan Li= ne..: %%H%d%%N\r\n" - " Pixel Info\r\n" - " RedMask.......= ....: %%H0x%08x%%N\r\n" - " GreenMask.....= ....: %%H0x%08x%%N\r\n" - " BlueMask......= ....: %%H0x%08x%%N\r\n" - -#string STR_GOP_RES_LIST_MAIN #language en-US " Supported Resoluti= on List" -#string STR_GOP_RES_LIST_ENTRY #language en-US "\r\n Resolution[%= %H%d%%N]:\r\n" - " Horizontal....= ....: %%H%d%%N\r\n" - " Vertical......= ....: %%H%d%%N" +#string STR_PCIRB_DUMP_PH #language en-US " ParentHandle..: %%H%x= %%N\r\n" +#string STR_PCIRB_DUMP_SEG #language en-US " Segment #.....: %%H%x= %%N\r\n" +#string STR_PCIRB_DUMP_ATT #language en-US " Attributes....: %%H%x= %%N\r\n" +#string STR_PCIRB_DUMP_SUPPORTS #language en-US " Supports......: %%H%x= %%N\r\n" +#string STR_PCIRB_DUMP_BUS #language en-US " BUS : " +#string STR_PCIRB_DUMP_MEM #language en-US " MEM : " +#string STR_PCIRB_DUMP_IO #language en-US " IO : " +#string STR_PCIRB_DUMP_TITLE #language en-US " Type Flag Base = Limit Gran\r\n" + " =3D=3D=3D=3D =3D=3D= =3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D" +#string STR_PCIIO_DUMP_MAIN #language en-US " Segment #.....: %02x\= r\n" + " Bus #.........: %02x\= r\n" + " Device #......: %02x\= r\n" + " Function #....: %02x\= r\n" + " ROM Size......: %lx\r= \n" + " ROM Location..: %08x\= r\n" + " Vendor ID.....: %04x\= r\n" + " Device ID.....: %04x\= r\n" + " Class Code....: %02x = %02x %02x\r\n" + " Configuration Header = :" +#string STR_USBIO_DUMP_MAIN #language en-US " Interface Number #...= ..: %02x\r\n" + " Interface Class #....= ..: %02x\r\n" + " Interface Subclass #.= ..: %02x\r\n" + " Interface Protocol #.= ..: %02x" + +#string STR_LI_DUMP_NAME #language en-US " Name..........: %%H%s= %%N\r\n" + +#string STR_LI_DUMP_MAIN #language en-US " Revision......: %%H0x= %08x%%N\r\n" + " ParentHandle..: %%H%x= %%N\r\n" + " SystemTable...: %%H%x= %%N\r\n" + " DeviceHandle..: %%H%x= %%N\r\n" + " FilePath......: %%H%s= %%N\r\n" + " PdbFileName...: %%H%a= %%N\r\n" + " OptionsSize...: %%H%x= %%N\r\n" + " LoadOptions...: %%H%x= %%N\r\n" + " ImageBase.....: %%H%x= %%N\r\n" + " ImageSize.....: %%H%L= x%%N\r\n" + " CodeType......: %%H%s= %%N\r\n" + " DataType......: %%H%s= %%N\r\n" + " Unload........: %%H%x= %%N" + +#string STR_GOP_DUMP_MAIN #language en-US " Max Mode.............= .: %%H0x%08x%%N\r\n" + " Current Mode.........= .: %%H0x%08x%%N\r\n" + " Frame Buffer Base....= .: %%H0x%L016x%%N\r\n" + " Frame Buffer Size....= .: %%H0x%L016x%%N\r\n" + " Mode Info Size.......= .: %%H0x%L016x%%N\r\n" + " Information\r\n" + " Version............= .: %%H0x%08x%%N\r\n" + " HorizontalResolutio= n: %%H%d%%N\r\n" + " VerticalResolution.= .: %%H%d%%N\r\n" + " Pixel Format.......= .: %%H%s%%N\r\n" + " Pixels / Scan Line.= .: %%H%d%%N\r\n" + " Pixel Info\r\n" + " RedMask..........= .: %%H0x%08x%%N\r\n" + " GreenMask........= .: %%H0x%08x%%N\r\n" + " BlueMask.........= .: %%H0x%08x%%N\r\n" + +#string STR_GOP_RES_LIST_MAIN #language en-US " Supported Resolution = List" +#string STR_GOP_RES_LIST_ENTRY #language en-US "\r\n" + " Resolution[%%H%d%%N= ]:\r\n" + " Horizontal.......= .: %%H%d%%N\r\n" + " Vertical.........= .: %%H%d%%N" #string STR_BSDO_DUMP_MAIN #language en-US " Drv[%02x] File:%%H= %s%%N" -#string STR_EDID_DISCOVERED_MAIN #language en-US " EDID Discovered Si= ze : %%H0x%08x%%N\r\n" -#string STR_EDID_DISCOVERED_DATA #language en-US " EDID Discovered Da= ta :\r\n" -#string STR_EDID_ACTIVE_MAIN #language en-US " EDID Active Size := %%H0x%08x%%N\r\n" -#string STR_EDID_ACTIVE_DATA #language en-US " EDID Active Data := \r\n" +#string STR_EDID_DISCOVERED_MAIN #language en-US " EDID Discovered Size = : %%H0x%08x%%N\r\n" +#string STR_EDID_DISCOVERED_DATA #language en-US " EDID Discovered Data = :\r\n" +#string STR_EDID_ACTIVE_MAIN #language en-US " EDID Active Size : %%= H0x%08x%%N\r\n" +#string STR_EDID_ACTIVE_DATA #language en-US " EDID Active Data :\r\= n" =20 #string STR_GET_SUPP_TYPES_FAILED #language en-US "Unable to get s= upported types - %%H%r%%N\r\n" #string STR_SUPP_TYPE_HEADER #language en-US " Supported Inf= ormation Types: \r\n" --=20 2.12.2.windows.2 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel