From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) (using TLSv1 with cipher CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 64F091A1E34 for ; Wed, 31 Aug 2016 00:08:04 -0700 (PDT) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga104.fm.intel.com with ESMTP; 31 Aug 2016 00:08:03 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,261,1470726000"; d="scan'208";a="162771971" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga004.fm.intel.com with ESMTP; 31 Aug 2016 00:08:04 -0700 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 31 Aug 2016 00:08:03 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.102]) by shsmsx102.ccr.corp.intel.com ([169.254.2.109]) with mapi id 14.03.0248.002; Wed, 31 Aug 2016 15:08:01 +0800 From: "Ni, Ruiyu" To: "Zeng, Star" , "edk2-devel@lists.01.org" CC: "Zeng, Star" Thread-Topic: [edk2] [PATCH] MdeModulePkg VarCheck: #### in L"Boot####" are upper case hex Thread-Index: AQHR/34RNAiuZBnnfEeo3TRusAXv86Birc3A Date: Wed, 31 Aug 2016 07:08:00 +0000 Message-ID: <734D49CCEBEEF84792F5B80ED585239D58D3FD4C@SHSMSX103.ccr.corp.intel.com> References: <1472204463-186244-1-git-send-email-star.zeng@intel.com> In-Reply-To: <1472204463-186244-1-git-send-email-star.zeng@intel.com> Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] MdeModulePkg VarCheck: #### in L"Boot####" are upper case hex 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: Wed, 31 Aug 2016 07:08:04 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Ruiyu Ni > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of > Star Zeng > Sent: Friday, August 26, 2016 5:41 PM > To: edk2-devel@lists.01.org > Cc: Ni, Ruiyu ; Zeng, Star > Subject: [edk2] [PATCH] MdeModulePkg VarCheck: #### in L"Boot####" are > upper case hex >=20 > UEFI spec: > Each load option entry resides in a Boot####, Driver####, SysPrep####, > OsRecovery#### or PlatformRecovery#### variable where #### is replaced > by a unique option number in printable hexadecimal representation using > the digits 0-9, and the upper case versions of the characters A-F (0000-F= FFF). >=20 > The patch also makes L"HwErrRec####" follow this rule. >=20 > Cc: Ruiyu Ni > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Star Zeng > --- > MdeModulePkg/Library/VarCheckLib/VarCheckLib.c | 16 ++++++++--= --- > --- > .../Library/VarCheckUefiLib/VarCheckUefiLibNullClass.c | 14 +++++++---= ---- > 2 files changed, 15 insertions(+), 15 deletions(-) >=20 > diff --git a/MdeModulePkg/Library/VarCheckLib/VarCheckLib.c > b/MdeModulePkg/Library/VarCheckLib/VarCheckLib.c > index 41b209da169f..5ca0d3edca44 100644 > --- a/MdeModulePkg/Library/VarCheckLib/VarCheckLib.c > +++ b/MdeModulePkg/Library/VarCheckLib/VarCheckLib.c > @@ -1,7 +1,7 @@ > /** @file > Implementation functions and structures for var check services. >=20 > -Copyright (c) 2015, Intel Corporation. All rights reserved.
> +Copyright (c) 2015 - 2016, 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 > @@ -96,17 +96,17 @@ VARIABLE_ENTRY_PROPERTY > mVarCheckVariableWithWildcardName[] =3D { }; >=20 > /** > - Check if a Unicode character is a hexadecimal character. > + Check if a Unicode character is an upper case hexadecimal character. >=20 > - This function checks if a Unicode character is a > - hexadecimal character. The valid hexadecimal character is > - L'0' to L'9', L'a' to L'f', or L'A' to L'F'. > + This function checks if a Unicode character is an upper case > + hexadecimal character. The valid upper case hexadecimal character is > + L'0' to L'9', or L'A' to L'F'. >=20 >=20 > @param[in] Char The character to check against. >=20 > - @retval TRUE If the Char is a hexadecmial character. > - @retval FALSE If the Char is not a hexadecmial character. > + @retval TRUE If the Char is an upper case hexadecmial charact= er. > + @retval FALSE If the Char is not an upper case hexadecmial cha= racter. >=20 > **/ > BOOLEAN > @@ -115,7 +115,7 @@ VarCheckInternalIsHexaDecimalDigitCharacter ( > IN CHAR16 Char > ) > { > - return (BOOLEAN) ((Char >=3D L'0' && Char <=3D L'9') || (Char >=3D L'A= ' && Char > <=3D L'F') || (Char >=3D L'a' && Char <=3D L'f')); > + return (BOOLEAN) ((Char >=3D L'0' && Char <=3D L'9') || (Char >=3D L'A= ' && > + Char <=3D L'F')); > } >=20 > /** > diff --git > a/MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLibNullClass.c > b/MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLibNullClass.c > index 8f7126e6aea6..80dc6341adcf 100644 > --- a/MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLibNullClass.c > +++ b/MdeModulePkg/Library/VarCheckUefiLib/VarCheckUefiLibNullClass.c > @@ -678,17 +678,17 @@ EFI_GUID *mUefiDefinedGuid[] =3D { }; >=20 > /** > - Check if a Unicode character is a hexadecimal character. > + Check if a Unicode character is an upper case hexadecimal character. >=20 > - This function checks if a Unicode character is a > - hexadecimal character. The valid hexadecimal character is > - L'0' to L'9', L'a' to L'f', or L'A' to L'F'. > + This function checks if a Unicode character is an upper case > + hexadecimal character. The valid upper case hexadecimal character is > + L'0' to L'9', or L'A' to L'F'. >=20 >=20 > @param[in] Char The character to check against. >=20 > - @retval TRUE If the Char is a hexadecmial character. > - @retval FALSE If the Char is not a hexadecmial character. > + @retval TRUE If the Char is an upper case hexadecmial charact= er. > + @retval FALSE If the Char is not an upper case hexadecmial cha= racter. >=20 > **/ > BOOLEAN > @@ -697,7 +697,7 @@ VarCheckUefiIsHexaDecimalDigitCharacter ( > IN CHAR16 Char > ) > { > - return (BOOLEAN) ((Char >=3D L'0' && Char <=3D L'9') || (Char >=3D L'A= ' && Char > <=3D L'F') || (Char >=3D L'a' && Char <=3D L'f')); > + return (BOOLEAN) ((Char >=3D L'0' && Char <=3D L'9') || (Char >=3D L'A= ' && > + Char <=3D L'F')); > } >=20 > /** > -- > 2.7.0.windows.1 >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel