From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) (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 DAFBD81F56 for ; Mon, 27 Feb 2017 08:36:51 -0800 (PST) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Feb 2017 08:36:51 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.35,215,1484035200"; d="scan'208";a="230237698" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by fmsmga004.fm.intel.com with ESMTP; 27 Feb 2017 08:36:51 -0800 Received: from fmsmsx151.amr.corp.intel.com (10.18.125.4) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.248.2; Mon, 27 Feb 2017 08:36:51 -0800 Received: from fmsmsx103.amr.corp.intel.com ([169.254.2.47]) by FMSMSX151.amr.corp.intel.com ([169.254.7.199]) with mapi id 14.03.0248.002; Mon, 27 Feb 2017 08:36:45 -0800 From: "Carsey, Jaben" To: "Ni, Ruiyu" , "edk2-devel@lists.01.org" CC: "Chen, Chen A" , "Carsey, Jaben" Thread-Topic: [edk2] [PATCH 1/2] ShellPkg/comp: Rename variable names to proper ones Thread-Index: AQHSjN/VBx656E0dgEeXNXQyUhagtKF9FZgw Date: Mon, 27 Feb 2017 16:36:44 +0000 Message-ID: References: <20170222074630.545800-1-ruiyu.ni@intel.com> <20170222074630.545800-2-ruiyu.ni@intel.com> In-Reply-To: <20170222074630.545800-2-ruiyu.ni@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZDYwNzY2N2UtNWY5YS00YzFkLTgyMTEtMmZiZTZlYmM3Y2MzIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6ImtIakxUTUY3a2k0STVXMk1zdzRGckJsY2ZBN0ErcWtPeUFWYnUzUHFydTA9In0= x-ctpclassification: CTP_IC x-originating-ip: [10.1.200.107] MIME-Version: 1.0 Subject: Re: [PATCH 1/2] ShellPkg/comp: Rename variable names to proper ones 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: Mon, 27 Feb 2017 16:36:52 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Jaben Carsey > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of > Ruiyu Ni > Sent: Tuesday, February 21, 2017 11:46 PM > To: edk2-devel@lists.01.org > Cc: Carsey, Jaben ; Chen, Chen A > > Subject: [edk2] [PATCH 1/2] ShellPkg/comp: Rename variable names to > proper ones > Importance: High >=20 > From: Chen A Chen >=20 > The change doesn't impact the functionality. >=20 > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Chen A Chen > Cc: Jaben Carsey > --- > ShellPkg/Library/UefiShellDebug1CommandsLib/Comp.c | 46 +++++++++++- > ---------- > 1 file changed, 23 insertions(+), 23 deletions(-) >=20 > diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/Comp.c > b/ShellPkg/Library/UefiShellDebug1CommandsLib/Comp.c > index 2ab7dd3..829c49a 100644 > --- a/ShellPkg/Library/UefiShellDebug1CommandsLib/Comp.c > +++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/Comp.c > @@ -2,7 +2,7 @@ > Main file for Comp shell Debug1 function. >=20 > (C) Copyright 2015 Hewlett-Packard Development Company, L.P.
> - Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved.
> + Copyright (c) 2010 - 2017, Intel Corporation. All rights reserved.
> This program and the accompanying materials > are licensed and made available under the terms and conditions of the = BSD > License > which accompanies this distribution. The full text of the license may= be > found at > @@ -31,11 +31,14 @@ ShellCommandRunComp ( > EFI_STATUS Status; > LIST_ENTRY *Package; > CHAR16 *ProblemParam; > + CHAR16 *FileName1; > + CHAR16 *FileName2; > + CONST CHAR16 *TempParam; > SHELL_STATUS ShellStatus; > UINTN LoopVar; > SHELL_FILE_HANDLE FileHandle1; > SHELL_FILE_HANDLE FileHandle2; > - UINT8 ErrorCount; > + UINT8 DifferentCount; > UINT64 Size1; > UINT64 Size2; > UINT8 DataFromFile1; > @@ -48,12 +51,9 @@ ShellCommandRunComp ( > UINT8 ADF_File23; > UINTN DataSizeFromFile1; > UINTN DataSizeFromFile2; > - CHAR16 *FileName1; > - CHAR16 *FileName2; > - CONST CHAR16 *TempParam; > - UINTN ErrorAddress; > + UINTN DiffPointAddress; >=20 > - ErrorCount =3D 0; > + DifferentCount =3D 0; > ShellStatus =3D SHELL_SUCCESS; > Status =3D EFI_SUCCESS; > FileName1 =3D NULL; > @@ -125,12 +125,12 @@ ShellCommandRunComp ( > ASSERT_EFI_ERROR(Status); > if (Size1 !=3D Size2) { > ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_COMP_SIZE_FAIL= ), > gShellDebug1HiiHandle); > - ErrorCount++; > + DifferentCount++; > ShellStatus =3D SHELL_NOT_EQUAL; > } > } > if (ShellStatus =3D=3D SHELL_SUCCESS) { > - for (LoopVar =3D 0 ; LoopVar < Size1 && ErrorCount <=3D 10 ; Loo= pVar++) { > + for (LoopVar =3D 0 ; LoopVar < Size1 && DifferentCount <=3D 10 ; > LoopVar++) { > DataSizeFromFile1 =3D 1; > DataSizeFromFile2 =3D 1; > Status =3D gEfiShellProtocol->ReadFile(FileHandle1, &DataSizeF= romFile1, > &DataFromFile1); > @@ -138,7 +138,7 @@ ShellCommandRunComp ( > Status =3D gEfiShellProtocol->ReadFile(FileHandle2, &DataSizeF= romFile2, > &DataFromFile2); > ASSERT_EFI_ERROR(Status); > if (DataFromFile1 !=3D DataFromFile2) { > - ErrorAddress =3D LoopVar; > + DiffPointAddress =3D LoopVar; > ADF_File11 =3D 0; > ADF_File12 =3D 0; > ADF_File13 =3D 0; > @@ -188,13 +188,13 @@ ShellCommandRunComp ( > NULL, > STRING_TOKEN (STR_COMP_SPOT_FAIL4), > gShellDebug1HiiHandle, > - ++ErrorCount, > + ++DifferentCount, > FileName1, > - ErrorAddress, > + DiffPointAddress, > DataFromFile1, ADF_File11, ADF_File12, ADF_File13, > DataFromFile1, ADF_File11, ADF_File12, ADF_File13, > FileName2, > - ErrorAddress, > + DiffPointAddress, > DataFromFile2, ADF_File21, ADF_File22, ADF_File23, > DataFromFile2, ADF_File21, ADF_File22, ADF_File23 > ); > @@ -205,13 +205,13 @@ ShellCommandRunComp ( > NULL, > STRING_TOKEN (STR_COMP_SPOT_FAIL3), > gShellDebug1HiiHandle, > - ++ErrorCount, > + ++DifferentCount, > FileName1, > - ErrorAddress, > + DiffPointAddress, > DataFromFile1, ADF_File11, ADF_File12, > DataFromFile1, ADF_File11, ADF_File12, > FileName2, > - ErrorAddress, > + DiffPointAddress, > DataFromFile2, ADF_File21, ADF_File22, > DataFromFile2, ADF_File21, ADF_File22 > ); > @@ -222,13 +222,13 @@ ShellCommandRunComp ( > NULL, > STRING_TOKEN (STR_COMP_SPOT_FAIL2), > gShellDebug1HiiHandle, > - ++ErrorCount, > + ++DifferentCount, > FileName1, > - ErrorAddress, > + DiffPointAddress, > DataFromFile1, ADF_File11, > DataFromFile1, ADF_File11, > FileName2, > - ErrorAddress, > + DiffPointAddress, > DataFromFile2, ADF_File21, > DataFromFile2, ADF_File21 > ); > @@ -239,13 +239,13 @@ ShellCommandRunComp ( > NULL, > STRING_TOKEN (STR_COMP_SPOT_FAIL1), > gShellDebug1HiiHandle, > - ++ErrorCount, > + ++DifferentCount, > FileName1, > - ErrorAddress, > + DiffPointAddress, > DataFromFile1, > DataFromFile1, > FileName2, > - ErrorAddress, > + DiffPointAddress, > DataFromFile2, > DataFromFile2 > ); > @@ -253,7 +253,7 @@ ShellCommandRunComp ( > ShellStatus =3D SHELL_NOT_EQUAL; > } > } > - if (ErrorCount =3D=3D 0) { > + if (DifferentCount =3D=3D 0) { > ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN > (STR_COMP_FOOTER_PASS), gShellDebug1HiiHandle); > } else { > ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN > (STR_COMP_FOOTER_FAIL), gShellDebug1HiiHandle); > -- > 2.9.0.windows.1 >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel