From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qk0-f170.google.com (mail-qk0-f170.google.com [209.85.220.170]) by dpdk.org (Postfix) with ESMTP id F166B8E9C for ; Wed, 14 Sep 2016 15:48:17 +0200 (CEST) Received: by mail-qk0-f170.google.com with SMTP id t7so13791386qkh.2 for ; Wed, 14 Sep 2016 06:48:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=DGTRbqNYN83rVB4ubGq0v15qOHoI/oEdiJM3x+VcRWE=; b=I5KcGM2Y2ukub3KhYF5OGgem3h06QS1r0eJ7W50qD2hixFfTk7aO0J2CDGbe8eY/rz hvAEOL2r5K+0/tpkPp3YMmDyyPEiP99nJArS5FqdWSWBsqGj+KYCUH372ElAyaCRG8n0 TsLrWjl844ZiIjGt/h7tPzYHO11qccT0fvndU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=DGTRbqNYN83rVB4ubGq0v15qOHoI/oEdiJM3x+VcRWE=; b=X8yPt4lJ0u8kl99I1xBhNCp8WON4+eJcYStSHZuUsY0W0qwu0yDoCPeBzojGB+5C3p e94swfPEgkB3p9kqdkSdBLcl5PAN74p1jr4oZY2B3Wv1YGK2xcqDoMGk3n6dT5HXAQxD IRqbTWInmUdIxoPRrybBCGqnrWVt2WY/CxG/P48hZNc8csDzR0aADvYx+eE4uQHxjjL2 NNU22HHAeTWOdUiLuxtLIu1vLMtsmTRTILMfnuZ9m/qJbRuND9ntrgOT/al8hsMpS70B X45w8aOHb6psN/6OcflNq1a7NkFdeQlLfRE64tpSFvG6MW0tghsXxaM+0LJkF6IN7uT7 Vztw== X-Gm-Message-State: AE9vXwPYbJypWcndfpeUeEA4+eXofomdQGgoC3Rwdj74AwwsQu1PZHYcO2o8DWmDVOBtX8Z8FVX+5FADHqm4FzU8 X-Received: by 10.55.214.68 with SMTP id t65mr3329010qki.216.1473860897260; Wed, 14 Sep 2016 06:48:17 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.42.180 with HTTP; Wed, 14 Sep 2016 06:47:36 -0700 (PDT) In-Reply-To: References: <2139728.s9C09RKb8B@xps13> <2164887.AxsOo2R2xv@xps13> From: Michael Wildt Date: Wed, 14 Sep 2016 09:47:36 -0400 Message-ID: To: Hemant Agrawal Cc: Thomas Monjalon , "users@dpdk.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] Cross compile for ARM64 fails due to librte_vhost and pmdinfogen issues X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Sep 2016 13:48:18 -0000 Hi Hemant, Thanks for the pointer to the 4.9.3 version. Haven't had issues with 4.9.2 but good to know. I gave that one a try and that works as well but as with the 5.3 I have to be on a Ubuntu not RHEL6 to make it work. Thanks, Michael On Wed, Sep 14, 2016 at 3:25 AM, Hemant Agrawal wrote: > Hi Michael, > One of the problem, I found with Linaro gcc 4.9 toolchain for i686 > (default one), that it seems to be built with older kernel headers (<3.8). > This usages older linux/vhost.h file. > > However, we have not observed this issue with x86_64 based toolchain on 64 > bit m/c. > https://releases.linaro.org/14.11/components/toolchain/ > binaries/aarch64-linux-gnu/ > > Regards, > Hemant > > > -----Original Message----- > > From: users [mailto:users-bounces@dpdk.org] On Behalf Of Michael Wildt > > Sent: Wednesday, September 14, 2016 12:05 AM > > To: Thomas Monjalon > > Cc: users@dpdk.org > > Subject: Re: [dpdk-users] Cross compile for ARM64 fails due to > librte_vhost and > > pmdinfogen issues > > > > Hi Thomas, > > > > The Linaro gcc 4.9 is correct when it gets to __GNUC_MINOR__, used a test > > application. Its actually 4.9.2. > > > > Tried a newer Linaro tool chain, turned out to be a bit more complicated > since > > that does not work on RHEL6, is however a success. With Linaro 5.3 one > can > > cross compile dpdk fine with no errors, though the rte_byteorder.h file > still > > points to arm's version, but pmdinfogen builds. > > > > Probably should still fix both issues just to keep the base clean. > > > > At least I have a workaround in the interim. > > > > Thanks for the help. > > > > Thanks, > > Michael > > > > > > On Tue, Sep 13, 2016 at 11:07 AM, Thomas Monjalon > > > > wrote: > > > > > 2016-09-13 07:45, Michael Wildt: > > > > Hi Thomas, > > > > > > > > Appreciate the assistance. Please see inline. > > > > > > > > > > > > On Tue, Sep 13, 2016 at 5:03 AM, Thomas Monjalon < > > > thomas.monjalon@6wind.com> > > > > wrote: > > > > > > > > > Hi, > > > > > > > > > > 2016-09-12 22:20, Michael Wildt: > > > > > > I'm attempting to cross compile DPDK on an x86 for an ARM64 > target. > > > This > > > > > > fails in the following areas, using latest dpdk as of 9/12. When > > > > > compiling > > > > > > natively there are no issues. > > > > > > > > > > Your analysis below seems good. > > > > > Interestingly, I do not see such error (don't know why). > > > > > Please could you share the commands you are using? > > > > > > > > > > > > > Sure can. > > > > > > > > make config T=arm64-armv8a-linuxapp-gcc CROSS=/projects/ccxsw/ > > > > toolchains/gcc-linaro-aarch64-linux-gnu-4.9-2014.09_linux/ > > > bin/aarch64-linux-gnu- > > > > ARCH=arm64 > > > > > > > > make T=arm64-armv8a-linuxapp-gcc CROSS=/projects/ccxsw/ > > > > toolchains/gcc-linaro-aarch64-linux-gnu-4.9-2014.09_linux/ > > > bin/aarch64-linux-gnu- > > > > ARCH=arm64 RTE_KERNELDIR=/projects/kernel > > > > > > > > > > - librte_vhost, fails with: > > > > > > > > > > > > /projects/dpdk_latest/lib/librte_vhost/vhost_user/virtio- > > > > > net-user.c:250:23: > > > > > > error: array subscript is above array bounds > [-Werror=array-bounds] > > > > > > rvq = dev->virtqueue[i * VIRTIO_QNUM + VIRTIO_RXQ]; > > > > > [...] > > > > > > - buildtools/pmdinfogen, fails with: > > > > > > > > > > > > == Build buildtools/pmdinfogen > > > > > > HOSTCC pmdinfogen.o > > > > > > /projects/dpdk_test_wget/dpdk-16.07/build/include/rte_ > byteorder.h: > > > > > > Assembler messages: > > > > > > /projects/dpdk_test_wget/dpdk-16.07/build/include/rte_ > > > byteorder.h:53: > > > > > > Error: no such instruction: `rev16 %bx,%bx' > > > > > [...] > > > > > > - The issue is due to the rte_byteorder.h file which gets > > > > > > symlink'ed with the ARM version at the beginning of the build. > > > > > > The pmdinfogen is always compiled for x86 thus the asm is > failing. > > > > > > It is definitely something to fix. > > > In the meantime, you should be able to compile DPDK by using a more > > > recent toolchain. This error is in: > > > > > > /* fix missing __builtin_bswap16 for gcc older then 4.8 */ #if > > > !(__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 8)) > > > > > > I know you are using gcc-4.9 but maybe __GNUC_MINOR__ is wrong in > yours. > > > > > > >