From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (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 5BEC781F6F for ; Thu, 9 Feb 2017 00:56:28 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx16.intmail.prod.int.phx2.redhat.com [10.5.11.28]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 74D2681254; Thu, 9 Feb 2017 08:56:28 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-116-51.phx2.redhat.com [10.3.116.51]) by smtp.corp.redhat.com (Postfix) with ESMTP id 676E1B5092; Thu, 9 Feb 2017 08:56:27 +0000 (UTC) To: Dandan Bi , edk2-devel@ml01.01.org References: <1486606121-226912-1-git-send-email-dandan.bi@intel.com> Cc: Jordan Justen , Liming Gao From: Laszlo Ersek Message-ID: Date: Thu, 9 Feb 2017 09:56:25 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <1486606121-226912-1-git-send-email-dandan.bi@intel.com> X-Scanned-By: MIMEDefang 2.74 on 10.5.11.28 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Thu, 09 Feb 2017 08:56:28 +0000 (UTC) Subject: Re: [PATCH v3] OvmfPkg/QemuBootOrderLib: Fix NOOPT build failure 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 08:56:28 -0000 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit On 02/09/17 03:08, Dandan Bi wrote: > This patch is to fix the IA32/NOOPT/VS Toolchain build failure. > The VS2015 failure log as below: > QemuBootOrderLib.lib(ExtraRootBusMap.obj) : > error LNK2001: unresolved external symbol __allmul > s:\..\Build\OvmfIa32\NOOPT_VS2015\IA32\MdeModulePkg\ > Universal\BdsDxe\BdsDxe\DEBUG\BdsDxe.dll : > fatal error LNK1120: 1 unresolved externals > NMAKE : fatal error U1077: > '"C:\Program Files\Microsoft Visual Studio 14.0\Vc\bin\link.exe"' : > return code '0x460' > Stop. Ah! So after all, it is the 64-bit multiplication implicit to the subscripting by a UINT64! That's something I'll have to keep in mind. Reviewed-by: Laszlo Ersek Thanks! Laszlo > > Cc: Jordan Justen > Cc: Laszlo Ersek > Cc: Liming Gao > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Dandan Bi > > Notes: > V3: Add VS compiler error message in commit log. > > --- > OvmfPkg/Library/QemuBootOrderLib/ExtraRootBusMap.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/OvmfPkg/Library/QemuBootOrderLib/ExtraRootBusMap.c b/OvmfPkg/Library/QemuBootOrderLib/ExtraRootBusMap.c > index ec42214..70ba161 100644 > --- a/OvmfPkg/Library/QemuBootOrderLib/ExtraRootBusMap.c > +++ b/OvmfPkg/Library/QemuBootOrderLib/ExtraRootBusMap.c > @@ -306,8 +306,8 @@ MapRootBusPosToBusNr ( > return EFI_INVALID_PARAMETER; > } > if (RootBusPos > ExtraRootBusMap->Count) { > return EFI_NOT_FOUND; > } > - *RootBusNr = ExtraRootBusMap->BusNumbers[RootBusPos - 1]; > + *RootBusNr = ExtraRootBusMap->BusNumbers[(UINTN)RootBusPos - 1]; > return EFI_SUCCESS; > } >