From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) (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 9D11081F35 for ; Thu, 9 Feb 2017 13:12:48 -0800 (PST) Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga102.jf.intel.com with ESMTP; 09 Feb 2017 13:12:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.35,137,1484035200"; d="scan'208";a="62858765" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by orsmga005.jf.intel.com with ESMTP; 09 Feb 2017 13:12:48 -0800 Received: from fmsmsx126.amr.corp.intel.com (10.18.125.43) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.248.2; Thu, 9 Feb 2017 13:12:48 -0800 Received: from fmsmsx103.amr.corp.intel.com ([169.254.2.47]) by FMSMSX126.amr.corp.intel.com ([169.254.1.200]) with mapi id 14.03.0248.002; Thu, 9 Feb 2017 13:12:47 -0800 From: "Carsey, Jaben" To: "Zeng, Star" , "edk2-devel@lists.01.org" CC: "Ni, Ruiyu" , "Carsey, Jaben" Thread-Topic: [PATCH] ShellPkg SmbiosView: Correct some outputs for Type 0/3/10 Thread-Index: AQHSgrZGoH+7RDWh/UKGjdjXvC60s6FhLRYw Date: Thu, 9 Feb 2017 21:12:47 +0000 Message-ID: References: <1486632241-43792-1-git-send-email-star.zeng@intel.com> In-Reply-To: <1486632241-43792-1-git-send-email-star.zeng@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYzJmZGQyMzAtMDVhMC00ZmFjLTkxMjItNGZhMWExMDE4OWFmIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6Ik55blwvUHBMd0pEUFRQTVUzM2p0WFAydTN3c2I5OTJKWjZNc2IrT3VBaFFNPSJ9 x-ctpclassification: CTP_IC x-originating-ip: [10.1.200.107] MIME-Version: 1.0 Subject: Re: [PATCH] ShellPkg SmbiosView: Correct some outputs for Type 0/3/10 X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Feb 2017 21:12:48 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Jaben Carsey > -----Original Message----- > From: Zeng, Star > Sent: Thursday, February 09, 2017 1:24 AM > To: edk2-devel@lists.01.org > Cc: Zeng, Star ; Ni, Ruiyu ; > Carsey, Jaben > Subject: [PATCH] ShellPkg SmbiosView: Correct some outputs for Type > 0/3/10 > Importance: High >=20 > Type 0: Update "EDD Enhanced Disk Driver)..." to > "EDD (Enhanced Disk Driver)..." for > STR_SMBIOSVIEW_PRINTINFO_EDD_ENHANCED_DRIVER >=20 > Type 3: Use L" Laptop" instead of L" LapTop" in > SystemEnclosureTypeTable to match SMBIOS spec. >=20 > Type 10: The BIT7 of Device Type is representing the > status of device whether it is enabled or disabled. > But current code is not considering the BIT7 and will > print "Undefined Value" for enabled device. Type 41 > has same definition of Device Type, the code is > correct and will be applied to Type 10 by this patch. >=20 > Cc: Ruiyu Ni > Cc: Jaben Carsey > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Star Zeng > --- > ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c | > 3 ++- > ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c > | 2 +- > .../UefiShellDebug1CommandsLib/SmbiosView/SmbiosViewStrings.uni | > 2 +- > 3 files changed, 4 insertions(+), 3 deletions(-) >=20 > diff --git > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > index 1d6002b92593..50d15ef1758e 100644 > --- > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > +++ > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > @@ -570,7 +570,8 @@ SmbiosPrintStructure ( > UINTN NumOfDevice; > NumOfDevice =3D (Struct->Type10->Hdr.Length - sizeof > (SMBIOS_STRUCTURE)) / (2 * sizeof (UINT8)); > for (Index =3D 0; Index < NumOfDevice; Index++) { > - DisplayOnboardDeviceTypes (Struct->Type10- > >Device[Index].DeviceType, Option); > + ShellPrintEx(-1,-1,(((Struct->Type10->Device[Index].DeviceType) = & > 0x80) !=3D 0) ? L"Device Enabled\n": L"Device Disabled\n"); > + DisplayOnboardDeviceTypes ((Struct->Type10- > >Device[Index].DeviceType) & 0x7F, Option); > ShellPrintHiiEx(-1,-1,NULL,STRING_TOKEN > (STR_SMBIOSVIEW_PRINTINFO_DESC_STRING), gShellDebug1HiiHandle); > ShellPrintEx(-1,-1,L"%a\n",LibGetSmbiosString (Struct, Struct->T= ype10- > >Device[Index].DescriptionString)); > } > diff --git > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > c > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > c > index 02d9ab1f57b3..afea429b7aa3 100644 > --- > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > c > +++ > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > c > @@ -166,7 +166,7 @@ TABLE_ITEM SystemEnclosureTypeTable[] =3D { > }, > { > 0x09, > - L" LapTop" > + L" Laptop" > }, > { > 0x0A, > diff --git > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView > Strings.uni > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView > Strings.uni > index 7d694536dbcd..2cd682630557 100644 > --- > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView > Strings.uni > +++ > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView > Strings.uni > @@ -133,7 +133,7 @@ > #string STR_SMBIOSVIEW_PRINTINFO_SELECTED_BOOT_SUPPORTED > #language en-US "Selectable Boot is supported\r\n" > #string STR_SMBIOSVIEW_PRINTINFO_BIOS_ROM_SOCKETED > #language en-US "BIOS ROM is socketed\r\n" > #string STR_SMBIOSVIEW_PRINTINFO_BOOT_FROM_PC_CARD > #language en-US "Boot From PC Card(PCMCIA)is supported\r\n" > -#string STR_SMBIOSVIEW_PRINTINFO_EDD_ENHANCED_DRIVER > #language en-US "EDD Enhanced Disk Driver) Specification is supported\r\n= " > +#string STR_SMBIOSVIEW_PRINTINFO_EDD_ENHANCED_DRIVER > #language en-US "EDD (Enhanced Disk Driver) Specification is supported\r\= n" > #string STR_SMBIOSVIEW_PRINTINFO_JAPANESE_FLOPPY_NEC > #language en-US "Int 13h - Japanese Floppy for NEC 9800 1.2mb (3.5\",1k > Bytes/Sector, 360 RPM) is supported\r\n" > #string STR_SMBIOSVIEW_PRINTINFO_JAPANESE_FLOPPY_TOSHIBA > #language en-US "Int 13h - Japanese Floppy for Toshiba 1.2mn (3.5\", 360 > RPM) is supported\r\n" > #string STR_SMBIOSVIEW_PRINTINFO_FLOPPY_SERVICES_SUPPORTED > #language en-US "Int 13h - 5.25\"/360KB Floppy Services are supported\r\n= " > -- > 2.7.0.windows.1