From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-002e3701.pphosted.com (mx0a-002e3701.pphosted.com [148.163.147.86]) by mx.groups.io with SMTP id smtpd.web12.1154.1571127544740206627 for ; Tue, 15 Oct 2019 01:19:05 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: hpe.com, ip: 148.163.147.86, mailfrom: prvs=019184da0c=abner.chang@hpe.com) Received: from pps.filterd (m0150241.ppops.net [127.0.0.1]) by mx0a-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x9F8GcXZ031990; Tue, 15 Oct 2019 08:19:04 GMT Received: from g9t5008.houston.hpe.com (g9t5008.houston.hpe.com [15.241.48.72]) by mx0a-002e3701.pphosted.com with ESMTP id 2vnaey80uc-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 15 Oct 2019 08:19:03 +0000 Received: from G9W8455.americas.hpqcorp.net (exchangepmrr1.us.hpecorp.net [16.216.161.94]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by g9t5008.houston.hpe.com (Postfix) with ESMTPS id 17EB953; Tue, 15 Oct 2019 08:19:03 +0000 (UTC) Received: from G2W6310.americas.hpqcorp.net (2002:10c5:4034::10c5:4034) by G9W8455.americas.hpqcorp.net (2002:10d8:a15e::10d8:a15e) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Tue, 15 Oct 2019 08:19:02 +0000 Received: from NAM03-CO1-obe.outbound.protection.outlook.com (15.241.52.11) by G2W6310.americas.hpqcorp.net (16.197.64.52) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Tue, 15 Oct 2019 08:19:02 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=d8Ph2O5OBUmxHzVpbdY2vCBq42rGmzM2TKro8r1fSce8ptZg2r3BkK4FU4/moFADSKvlzcLylW5iJc+GiX6i1zl/RZbnPTqO0HW3wx1uAhW8Sj6PEwRr/ggCmkKzQRW3HSpDOpZyUSC0k0rl3c1y7hAxhhlfQWg3GPBhZPFyobiWwNw8JfqAQwny/4ahFXSXNhE6Ld7LAriaKeSmo7V0UuR10ndcKhhqjqdIRhNp4588SrUgKJtsUmInSJIJgX2j77ItsI1CduIl6ISQvyHWsPJEWltFS+RlVZRz/wDAZfSGaXBKbb8YEMw++0ExLxcOplRJNn0iXXiiXg166F0Vcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kde4oXO2Q0e2TnviEO1RaMh8DZKeyzrByRL/gd9rrH0=; b=g5ljLXIcHiGsxZ9D1IESOWzyS4r4ssm2KaycvR56B8UiU7tIsa/Yq6Vo69O8WWPOFU0FPZ3mPxcu4SgDISbfrs7lcYRXjn7jLB1wsI6KTEnb30NTELLd/QjsxM0eoiTQj/bN04mXdgyNLzC/FoqlLlqxVxoDgLb56gcL2DuVBuI/JoxXgthreiWZIymbgB323UXICZmul8iJ39XKEV1Bra/gmGIcOhekcpqpWlEBCCE8BnIjj1hMOL6gdO7SFr9V9INcwrZoNb+XcDS3tGe7sjvKBEfWTsW21XUb1OuyWvjTd3TXxWaMXr9g7Qqccg5ZwOoOxGnrCnMwSzgLpoxWvg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=hpe.com; dmarc=pass action=none header.from=hpe.com; dkim=pass header.d=hpe.com; arc=none Received: from CS1PR8401MB1192.NAMPRD84.PROD.OUTLOOK.COM (10.169.12.151) by CS1PR8401MB0600.NAMPRD84.PROD.OUTLOOK.COM (10.169.13.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2347.16; Tue, 15 Oct 2019 08:19:00 +0000 Received: from CS1PR8401MB1192.NAMPRD84.PROD.OUTLOOK.COM ([fe80::4fb:84b9:76e6:1cde]) by CS1PR8401MB1192.NAMPRD84.PROD.OUTLOOK.COM ([fe80::4fb:84b9:76e6:1cde%8]) with mapi id 15.20.2347.023; Tue, 15 Oct 2019 08:19:00 +0000 From: "Abner Chang" To: "devel@edk2.groups.io" , "zhichao.gao@intel.com" CC: "Carsey, Jaben" , "Ni, Ray" , Leif Lindholm , "Chen, Gilbert" Subject: Re: [edk2-devel] [PATCH v6 3/3] ShellPkg/UefiShellDebug1CommandsLib: Update to support SmBios 3.3.0 Thread-Topic: [edk2-devel] [PATCH v6 3/3] ShellPkg/UefiShellDebug1CommandsLib: Update to support SmBios 3.3.0 Thread-Index: AQHVfnWZdOy0zlno/EGpGE4rjp5o7KdbZTKw Date: Tue, 15 Oct 2019 08:19:00 +0000 Message-ID: References: <1570603672-13955-1-git-send-email-abner.chang@hpe.com> <3CE959C139B4C44DBEA1810E3AA6F9000B851B60@SHSMSX101.ccr.corp.intel.com> In-Reply-To: <3CE959C139B4C44DBEA1810E3AA6F9000B851B60@SHSMSX101.ccr.corp.intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [16.242.247.131] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 29e1dc94-d10d-4caf-11b0-08d75148555b x-ms-office365-filtering-ht: Tenant x-ms-traffictypediagnostic: CS1PR8401MB0600: x-ms-exchange-purlcount: 2 x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2733; x-forefront-prvs: 01917B1794 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(6029001)(346002)(39860400002)(136003)(396003)(376002)(366004)(13464003)(199004)(189003)(86362001)(6116002)(478600001)(316002)(486006)(6506007)(19627235002)(102836004)(229853002)(8676002)(81156014)(81166006)(15650500001)(5660300002)(4326008)(53546011)(305945005)(476003)(7736002)(8936002)(71190400001)(3846002)(52536014)(2501003)(110136005)(54906003)(14454004)(6306002)(6246003)(7696005)(2906002)(66066001)(11346002)(186003)(99286004)(74316002)(966005)(446003)(33656002)(76116006)(66476007)(66446008)(9686003)(66946007)(66556008)(64756008)(26005)(256004)(6436002)(71200400001)(25786009)(55016002)(76176011)(14444005);DIR:OUT;SFP:1102;SCL:1;SRVR:CS1PR8401MB0600;H:CS1PR8401MB1192.NAMPRD84.PROD.OUTLOOK.COM;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: hpe.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: a7DzTp5meujJAHx1eXWa6PPlMGqSYyZuswsYyv8D8+Po2QVy24/o7DPkXxBowZcF0jOGCwozAoCa3432VBmPF115tSuyOCTe7ZwTG6JAW8qYClaz2LzLrAXPQRobzyuJ90rPsfkTKFyUuoWmybDKiwgYKegHUQZhzhTqPo1mWVNZ4JkItplx7ceWk+DJLyvdfEVztgIR4hTmk7EfwRZK3EsBVlkeIgNonsMQrfvlmSSfeak4Br1Ul2J9kBB/cIgfZKaEPkqxn3Z9ucImZWY7P+D0nL9jp/EQTfluHkzxxKEfUJBmXQw30qBjDedAuRs1cXd9fQ/l14Ylpmp1H5pix5q9gt/7PUshO+jvscKa1Yi1PZo+V7c357FYbid18WpCkP8q2upv5phBIPKw+xo4n+kx9eVl1wIfXmEnLLxSxOYnF5gJ1VGBGez6S3AGWXfkfFVjBJSSEifpdZQ3JSUckQ== X-MS-Exchange-CrossTenant-Network-Message-Id: 29e1dc94-d10d-4caf-11b0-08d75148555b X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Oct 2019 08:19:00.5532 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 105b2061-b669-4b31-92ac-24d304d195dc X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 9D4eS5bnN6NDgNkw2VJRhlGEQWis8mure25E26F+PkZ8qnE0Z2GvjehGHSSNCv0qyjWlBtZ2sWXJ5DOWQXlZIA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CS1PR8401MB0600 X-OriginatorOrg: hpe.com X-Proofpoint-UnRewURL: 0 URL was un-rewritten MIME-Version: 1.0 X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.95,1.0.8 definitions=2019-10-15_04:2019-10-15,2019-10-15 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 bulkscore=0 clxscore=1015 priorityscore=1501 mlxlogscore=999 lowpriorityscore=0 spamscore=0 phishscore=0 malwarescore=0 mlxscore=0 suspectscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-1908290000 definitions=main-1910150076 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I got it, v7 just sent. Please check it out. Thanks Abner > -----Original Message----- > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of > Gao, Zhichao > Sent: Wednesday, October 9, 2019 3:46 PM > To: devel@edk2.groups.io; Chang, Abner (HPS SW/FW Technologist) > > Cc: Carsey, Jaben ; Ni, Ray ; > Leif Lindholm ; Chen, Gilbert > > Subject: Re: [edk2-devel] [PATCH v6 3/3] > ShellPkg/UefiShellDebug1CommandsLib: Update to support SmBios 3.3.0 >=20 > Thanks for take my suggestion. But you may forget the other one. > What I said is that moving the display functions into one function, not = just > removing one of them. > Here is the example: > VOID > DisplayProcessorArchitectureType ( > IN UINT8 Key, > IN UINT8 Option > ) > { > ShellPrintHiiEx (-1,-1,NULL,STRING_TOKEN > (STR_SMBIOSVIEW_QUERYTABLE_PROCESSOR_ARCH_TYPE), > gShellDebug1HiiHandle); > PRINT_INFO_OPTION (Key, Option); > PRINT_TABLE_ITEM (ProcessorArchitectureTypesTable, Key); } >=20 > And you should add the > STR_SMBIOSVIEW_QUERYTABLE_PROCESSOR_ARCH_TYPE to the > SmbiosViewStrings.uni file with an appropriate string like "Process > Architecture Type:". >=20 > In my opinion, PRINT_STRUCT_VALUE_H is used to print the field's name an= d > hex value without any explain of the value. And DisplayXXX function is u= sed > to display the field's name, field's value and the meaning of the value. >=20 > Thanks, > Zhichao >=20 > > -----Original Message----- > > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of > > Abner Chang > > Sent: Wednesday, October 9, 2019 2:48 PM > > To: devel@edk2.groups.io > > Cc: abner.chang@hpe.com; Carsey, Jaben ; Ni, > > Ray ; Gao, Zhichao ; Leif > > Lindholm ; Gilbert Chen > > > > Subject: [edk2-devel] [PATCH v6 3/3] > > ShellPkg/UefiShellDebug1CommandsLib: Update to support SmBios 3.3.0 > > > > Shell command smbiosview updates for SMBIOS 3.3.0 spec. > > > > Bugzilla link, > > INVALID URI REMOVED > > e.org_show-5Fbug.cgi-3Fid- > 3D2202&d=3DDwIFAg&c=3DC5b8zRQO1miGmBeVZ2LFWg&r=3D_ > > SN6FZBN4Vgi4Ulkskz6qU3NYRO03nHp9P7Z5q59A3E&m=3DTs3QFi- > 9F2sWNpLDpzAZ7jo9i > > 58P5EIBxBTKE-hNKlw&s=3D74gcG5cccnAwHeMzaoABWbMurL1drLiJ02LFb8n- > POw&e=3D > > > > Signed-off-by: Abner Chang > > > > Cc: Jaben Carsey > > Cc: Ray Ni > > Cc: Zhichao Gao > > Cc: Leif Lindholm > > Cc: Gilbert Chen > > --- > > .../SmbiosView/PrintInfo.c | 22 +++++++- > > .../SmbiosView/PrintInfo.h | 13 ++++- > > .../SmbiosView/QueryTable.c | 63 +++++++++++++= ++++++++- > > .../UefiShellDebug1CommandsLib.uni | 3 +- > > 4 files changed, 97 insertions(+), 4 deletions(-) > > > > diff --git > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > > index cfd7a2b..4989102 100644 > > --- > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > > +++ > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c > > @@ -3,7 +3,7 @@ > > > > Copyright (c) 2005 - 2018, Intel Corporation. All rights reserved.<= BR> > > (C) Copyright 2014 Hewlett-Packard Development Company, L.P.
> > - (C) Copyright 2015-2017 Hewlett Packard Enterprise Development > > LP
> > + (C) Copyright 2015-2019 Hewlett Packard Enterprise Development > > + LP
> > SPDX-License-Identifier: BSD-2-Clause-Patent > > > > **/ > > @@ -1169,6 +1169,14 @@ SmbiosPrintStructure ( > > break; > > > > // > > + // Processor Additional Information (Type 44) // case 44: > > + PRINT_STRUCT_VALUE_H (Struct, Type44, RefHandle); > > + DisplayProcessorArchitectureType (Struct->Type44- > > >ProcessorSpecificBlock.ProcessorArchType, Option); > > + break; > > + > > + // > > // Inactive (Type 126) > > // > > case 126: > > @@ -2350,6 +2358,18 @@ DisplayProcessorFamily2 ( > > Print (L"Video Processor\n"); > > break; > > > > + case 0x200: > > + Print (L"RISC-V RV32\n"); > > + break; > > + > > + case 0x201: > > + Print (L"RISC-V RV64\n"); > > + break; > > + > > + case 0x202: > > + Print (L"RISC-V RV128\n"); > > + break; > > + > > default: > > ShellPrintHiiEx(-1,-1,NULL,STRING_TOKEN > > (STR_SMBIOSVIEW_PRINTINFO_UNDEFINED_PROC_FAMILY), > > gShellDebug1HiiHandle); > > } > > diff --git > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.h > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.h > > index a8c32ab..77a86fc 100644 > > --- > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.h > > +++ > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.h > > @@ -2,7 +2,7 @@ > > Module to clarify the element info of the smbios structure. > > > > Copyright (c) 2005 - 2015, Intel Corporation. All rights > > reserved.
> > - (C) Copyright 2017 Hewlett Packard Enterprise Development LP
> > + (C) Copyright 2017 - 2019 Hewlett Packard Enterprise Development > > + LP
> > SPDX-License-Identifier: BSD-2-Clause-Patent > > > > **/ > > @@ -427,4 +427,15 @@ DisplayTpmDeviceCharacteristics ( > > IN UINT8 Option > > ); > > > > +/** > > + Display Processor Architecture Type (Type 44). > > + > > + @param[in] Key The key of the structure. > > + @param[in] Option The optional information. > > +**/ > > +VOID > > +DisplayProcessorArchitectureType ( > > + IN UINT8 Key, > > + IN UINT8 Option > > + ); > > #endif > > diff --git > > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > > c > > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > > c > > index bfb7c3b..ef098ad 100644 > > --- > > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > > c > > +++ > > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable. > > +++ c > > @@ -3,7 +3,7 @@ > > And give a interface of query a string out of a table. > > > > Copyright (c) 2005 - 2018, Intel Corporation. All rights > > reserved.
> > - (C) Copyright 2016-2017 Hewlett Packard Enterprise Development > > LP
> > + (C) Copyright 2016-2019 Hewlett Packard Enterprise Development > > + LP
> > SPDX-License-Identifier: BSD-2-Clause-Patent > > > > **/ > > @@ -620,6 +620,10 @@ TABLE_ITEM ProcessorCharacteristicsTable[] =3D { > > { > > 7, > > L" Power/Performance Control" > > + }, > > + { > > + 8, > > + L" 128-bit Capable" > > } > > }; > > > > @@ -3268,6 +3272,44 @@ TABLE_ITEM MCHostInterfaceTypeTable[] =3D { > > }, > > }; > > > > +TABLE_ITEM ProcessorArchitectureTypesTable[] =3D { > > + { > > + 0, > > + L" Reserved " > > + }, > > + { > > + 1, > > + L" IA32 (x86) " > > + }, > > + { > > + 2, > > + L" x64 (x86-64, intel64, AMD64, EM64T) " > > + }, > > + { > > + 3, > > + L" Intel Itanium architecture " > > + }, > > + { > > + 4, > > + L" 32-bit ARM (Aarch32) " > > + }, > > + { > > + 5, > > + L" 64-bit ARM (Aarch64) " > > + }, > > + { > > + 6, > > + L" 32-bit RISC-V (RV32) " > > + }, > > + { > > + 7, > > + L" 64-bit RISC-V (RV64) " > > + }, > > + { > > + 8, > > + L" 128-bit RISC-V (RV128) " > > + } > > +}; > > > > TABLE_ITEM StructureTypeInfoTable[] =3D { > > { > > @@ -3447,6 +3489,10 @@ TABLE_ITEM StructureTypeInfoTable[] =3D { > > L" TPM Device" > > }, > > { > > + 44, > > + L" Processor Additional Information" > > + }, > > + { > > 0x7E, > > L" Inactive" > > }, > > @@ -4697,6 +4743,21 @@ DisplayMCHostInterfaceType ( } > > > > /** > > + Display Processor Architecture Type (Type 44). > > + > > + @param[in] Key The key of the structure. > > + @param[in] Option The optional information. > > +**/ > > +VOID > > +DisplayProcessorArchitectureType ( > > + IN UINT8 Key, > > + IN UINT8 Option > > + ) > > +{ > > + PRINT_TABLE_ITEM (ProcessorArchitectureTypesTable, Key); } > > + > > +/** > > Display the structure type information. > > > > @param[in] Key The key of the structure. > > diff --git > > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1Comman > > dsLib.uni > > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1Comman > > dsLib.uni > > index 42a9295..6693be2 100644 > > --- > > > a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1Comman > > dsLib.uni > > +++ > > > b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1Comman > > d > > +++ sLib.uni > > @@ -2,7 +2,7 @@ > > // > > // Copyright (c) 2010 - 2018, Intel Corporation. All rights > > reserved.
// (C) Copyright 2013-2015 Hewlett-Packard Development > > Company, L.P.
-// > > (C) Copyright 2016 Hewlett Packard Enterprise Development LP
> > +// (C) Copyright 2016 - 2019 Hewlett Packard Enterprise Development > > +LP
> > // SPDX-License-Identifier: BSD-2-Clause-Patent // // Module Name: > > @@ -976,6 +976,7 @@ > > " 41 - Onboard Devices Extended Information\r\n" > > " 42 - Management Controller Host Interface\r\n" > > " 43 - TPM Device\r\n" > > +" 44 - Processor Additional Information\r\n" > > " 2. Enter the SmbiosHandle parameter in hexadecimal format.\r\n" > > " Do not use the '0x' prefix format for hexadecimal values.\r\n" > > " 3. Internal commands:\r\n" > > -- > > 2.7.4 > > > > > > >=20 >=20 >=20