From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.43; helo=mga05.intel.com; envelope-from=jaben.carsey@intel.com; receiver=edk2-devel@lists.01.org Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) (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 6483421962301 for ; Thu, 29 Nov 2018 07:17:12 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Nov 2018 07:17:11 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,295,1539673200"; d="scan'208";a="96787083" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga008.jf.intel.com with ESMTP; 29 Nov 2018 07:17:11 -0800 Received: from fmsmsx116.amr.corp.intel.com (10.18.116.20) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 29 Nov 2018 07:17:11 -0800 Received: from fmsmsx103.amr.corp.intel.com ([169.254.2.186]) by fmsmsx116.amr.corp.intel.com ([169.254.2.70]) with mapi id 14.03.0415.000; Thu, 29 Nov 2018 07:17:10 -0800 From: "Carsey, Jaben" To: Ard Biesheuvel , "edk2-devel@lists.01.org" CC: Laszlo Ersek , "Gao, Liming" Thread-Topic: [edk2] [PATCH 3/6] BaseTools/DevicePath: use explicit 64-bit number parsing routines Thread-Index: AQHUh9+CtQC9kY9iM0Oct/a36EP7VqVm3W5Q Date: Thu, 29 Nov 2018 15:17:09 +0000 Message-ID: References: <20181129123129.25095-1-ard.biesheuvel@linaro.org> <20181129123129.25095-4-ard.biesheuvel@linaro.org> In-Reply-To: <20181129123129.25095-4-ard.biesheuvel@linaro.org> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZDM0ZjM3YTQtNDBiMC00NGZkLTgyMTQtNTNkYzYyYWM4ODNhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiaEhzQnBSRGorZDMyNWZPcTZvSHZNM1EzQTRhZE5sMEYzQUs5a3RNYXdYWlhkTmp4Y2dTMnlVWXRRZUMwXC95cWEifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.1.200.106] MIME-Version: 1.0 Subject: Re: [PATCH 3/6] BaseTools/DevicePath: use explicit 64-bit number parsing routines X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Nov 2018 15:17:12 -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 > Ard Biesheuvel > Sent: Thursday, November 29, 2018 4:31 AM > To: edk2-devel@lists.01.org > Cc: Laszlo Ersek ; Gao, Liming > Subject: [edk2] [PATCH 3/6] BaseTools/DevicePath: use explicit 64-bit > number parsing routines >=20 > Replace invocations of StrHexToUintn() with StrHexToUint64(), so > that we can drop the former. >=20 > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Ard Biesheuvel > --- > BaseTools/Source/C/DevicePath/DevicePathFromText.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/BaseTools/Source/C/DevicePath/DevicePathFromText.c > b/BaseTools/Source/C/DevicePath/DevicePathFromText.c > index 555efa1acdde..6151926af9aa 100644 > --- a/BaseTools/Source/C/DevicePath/DevicePathFromText.c > +++ b/BaseTools/Source/C/DevicePath/DevicePathFromText.c > @@ -520,7 +520,7 @@ EisaIdFromText ( > return (((Text[0] - 'A' + 1) & 0x1f) << 10) > + (((Text[1] - 'A' + 1) & 0x1f) << 5) > + (((Text[2] - 'A' + 1) & 0x1f) << 0) > - + (UINT32) (StrHexToUintn (&Text[3]) << 16) > + + (UINT32) (StrHexToUint64 (&Text[3]) << 16) > ; > } >=20 > @@ -1506,7 +1506,7 @@ DevPathFromTextNVMe ( >=20 > Index =3D sizeof (Nvme->NamespaceUuid) / sizeof (UINT8); > while (Index-- !=3D 0) { > - Uuid[Index] =3D (UINT8) StrHexToUintn (SplitStr (&NamespaceUuidStr, = L'- > ')); > + Uuid[Index] =3D (UINT8) StrHexToUint64 (SplitStr (&NamespaceUuidStr,= L'- > ')); > } >=20 > return (EFI_DEVICE_PATH_PROTOCOL *) Nvme; > -- > 2.19.1 >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel