From patchwork Thu Mar 19 07:51:38 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lance Yang X-Patchwork-Id: 1258100 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.137; helo=fraxinus.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=arm.com Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48jjbN0lM9z9sSM for ; Thu, 19 Mar 2020 21:20:32 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 8B01186B90; Thu, 19 Mar 2020 10:20:30 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bwaW6ox_BaRz; Thu, 19 Mar 2020 10:20:29 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by fraxinus.osuosl.org (Postfix) with ESMTP id E69CD86102; Thu, 19 Mar 2020 10:20:29 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id D7EC2C1830; Thu, 19 Mar 2020 10:20:29 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by lists.linuxfoundation.org (Postfix) with ESMTP id EF3FEC07FF for ; Thu, 19 Mar 2020 10:20:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id DF3548614E for ; Thu, 19 Mar 2020 10:20:27 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id m9_Fd2gX9975 for ; Thu, 19 Mar 2020 10:20:27 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by fraxinus.osuosl.org (Postfix) with ESMTP id EFC1D86102 for ; Thu, 19 Mar 2020 10:20:26 +0000 (UTC) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 2986931B; Thu, 19 Mar 2020 03:20:26 -0700 (PDT) Received: from nfv-demo01.shanghai.arm.com (unknown [10.169.41.196]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 0BB773FA53; Thu, 19 Mar 2020 00:52:05 -0700 (PDT) From: Lance Yang To: ovs-dev@openvswitch.org Date: Thu, 19 Mar 2020 15:51:38 +0800 Message-Id: <1584604298-25962-1-git-send-email-Lance.Yang@arm.com> X-Mailer: git-send-email 2.7.4 Cc: Gavin.Hu@arm.com, i.maximets@ovn.org, nd@arm.com, Ruifeng.Wang@arm.com Subject: [ovs-dev] [PATCH v3]travis: Enable OvS Travis CI for arm. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" Enable part of travis jobs with gcc compiler for arm64 architecture 1. Add arm jobs into the matrix in .travis.yml configuration file 2. To enable OVS-DPDK jobs, set the build target according to different CPU architectures 3. Temporarily disable sparse checker because of static code checking failure on arm64 Considering the balance of the CI coverage and running time, some kernel and DPDK jobs are removed from Arm CI. The running time increases around by 7 minutes to 47 minutes in all. Successful travis build jobs report: https://travis-ci.org/github/yzyuestc/ovs/builds/663833478 Reviewed-by: Yanqin Wei Reviewed-by: Ruifeng Wang Reviewed-by: JingZhao Ni Reviewed-by: Gavin Hu Signed-off-by: Lance Yang --- v3: - Remove some kernel jobs: 4.18, 4.17, 4.16, 4.15, 4.14, and 4.3. - Remove one OvS-DPDK shared library job. --- .travis.yml | 15 +++++++++++++++ .travis/linux-build.sh | 16 ++++++++++++++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index ef9f867..1149758 100644 --- a/.travis.yml +++ b/.travis.yml @@ -51,6 +51,21 @@ matrix: - os: osx compiler: clang env: OPTS="--disable-ssl" + - arch: arm64 + compiler: gcc + env: OPTS="--disable-ssl" + - arch: arm64 + compiler: gcc + env: KERNEL_LIST="5.5 4.19" + - arch: arm64 + compiler: gcc + env: KERNEL_LIST="4.9 3.16" + - arch: arm64 + compiler: gcc + env: DPDK=1 OPTS="--enable-shared" + - arch: arm64 + compiler: gcc + env: DPDK_SHARED=1 script: ./.travis/${TRAVIS_OS_NAME}-build.sh $OPTS diff --git a/.travis/linux-build.sh b/.travis/linux-build.sh index 359f777..3140ec9 100755 --- a/.travis/linux-build.sh +++ b/.travis/linux-build.sh @@ -6,7 +6,7 @@ set -x CFLAGS_FOR_OVS="-g -O2" SPARSE_FLAGS="" EXTRA_OPTS="--enable-Werror" -TARGET="x86_64-native-linuxapp-gcc" +TARGET="" function install_kernel() { @@ -87,6 +87,16 @@ function install_dpdk() local DPDK_VER=$1 local VERSION_FILE="dpdk-dir/travis-dpdk-cache-version" + if [ -z "$TRAVIS_ARCH" ] || + [ "$TRAVIS_ARCH" == "amd64" ]; then + TARGET="x86_64-native-linuxapp-gcc" + elif [ "$TRAVIS_ARCH" == "aarch64" ]; then + TARGET="arm64-armv8a-linuxapp-gcc" + else + echo "Target is unknown" + exit 1 + fi + if [ "${DPDK_VER##refs/*/}" != "${DPDK_VER}" ]; then # Avoid using cache for git tree build. rm -rf dpdk-dir @@ -178,7 +188,9 @@ elif [ "$M32" ]; then # difference on 'configure' and 'make' stages. export CC="$CC -m32" else - OPTS="--enable-sparse" + if [ "$TRAVIS_ARCH" != "aarch64" ]; then + OPTS="--enable-sparse" + fi if [ "$AFXDP" ]; then # netdev-afxdp uses memset for 64M for umem initialization. SPARSE_FLAGS="${SPARSE_FLAGS} -Wno-memcpy-max-count"