From patchwork Mon Dec 4 11:15:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Kavanagh X-Patchwork-Id: 844199 X-Patchwork-Delegate: ian.stokes@intel.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yr2Q94kRqz9t16 for ; Mon, 4 Dec 2017 22:16:49 +1100 (AEDT) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 79EABC0C; Mon, 4 Dec 2017 11:16:13 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 112DFC09 for ; Mon, 4 Dec 2017 11:16:12 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 59B14189 for ; Mon, 4 Dec 2017 11:16:11 +0000 (UTC) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 04 Dec 2017 03:16:11 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,359,1508828400"; d="scan'208";a="9301024" Received: from silpixa00399778.ir.intel.com ([10.237.222.206]) by orsmga003.jf.intel.com with ESMTP; 04 Dec 2017 03:16:09 -0800 From: Mark Kavanagh To: dev@openvswitch.org Date: Mon, 4 Dec 2017 11:15:58 +0000 Message-Id: <1512386159-236028-2-git-send-email-mark.b.kavanagh@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1512386159-236028-1-git-send-email-mark.b.kavanagh@intel.com> References: <1512386159-236028-1-git-send-email-mark.b.kavanagh@intel.com> X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Cc: maxime.coquelin@redhat.com, i.maximets@samsung.com Subject: [ovs-dev] [PATCH V4 1/2] netdev-dpdk: DPDK v17.11 upgrade X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org This commit adds support for DPDK v17.11: - minor updates to accomodate DPDK API changes - update references to DPDK version in Documentation - update DPDK version in travis' linux-build script Signed-off-by: Mark Kavanagh Acked-by: Maxime Coquelin Acked-by: Ciara Loftus Acked-by: Jan Scheurich Tested-by: Jan Scheurich --- .travis/linux-build.sh | 2 +- Documentation/faq/releases.rst | 1 + Documentation/intro/install/dpdk.rst | 10 +++++----- Documentation/topics/dpdk/ring.rst | 2 +- Documentation/topics/dpdk/vhost-user.rst | 8 ++++---- NEWS | 2 ++ lib/netdev-dpdk.c | 5 +++-- 7 files changed, 17 insertions(+), 13 deletions(-) diff --git a/.travis/linux-build.sh b/.travis/linux-build.sh index 4d6459f..ed28ee4 100755 --- a/.travis/linux-build.sh +++ b/.travis/linux-build.sh @@ -81,7 +81,7 @@ fi if [ "$DPDK" ]; then if [ -z "$DPDK_VER" ]; then - DPDK_VER="17.05.2" + DPDK_VER="17.11" fi install_dpdk $DPDK_VER if [ "$CC" = "clang" ]; then diff --git a/Documentation/faq/releases.rst b/Documentation/faq/releases.rst index d903b06..62a1957 100644 --- a/Documentation/faq/releases.rst +++ b/Documentation/faq/releases.rst @@ -164,6 +164,7 @@ Q: What DPDK version does each Open vSwitch release work with? 2.6.x 16.07.2 2.7.x 16.11.3 2.8.x 17.05.2 + 2.9.x 17.11 ============ ======= Q: I get an error like this when I configure Open vSwitch: diff --git a/Documentation/intro/install/dpdk.rst b/Documentation/intro/install/dpdk.rst index bb69ae5..3fecb5c 100644 --- a/Documentation/intro/install/dpdk.rst +++ b/Documentation/intro/install/dpdk.rst @@ -40,7 +40,7 @@ Build requirements In addition to the requirements described in :doc:`general`, building Open vSwitch with DPDK will require the following: -- DPDK 17.05.2 +- DPDK 17.11 - A `DPDK supported NIC`_ @@ -69,9 +69,9 @@ Install DPDK #. Download the `DPDK sources`_, extract the file and set ``DPDK_DIR``:: $ cd /usr/src/ - $ wget http://fast.dpdk.org/rel/dpdk-17.05.2.tar.xz - $ tar xf dpdk-17.05.2.tar.xz - $ export DPDK_DIR=/usr/src/dpdk-stable-17.05.2 + $ wget http://fast.dpdk.org/rel/dpdk-17.11.tar.xz + $ tar xf dpdk-17.11.tar.xz + $ export DPDK_DIR=/usr/src/dpdk-17.11 $ cd $DPDK_DIR #. (Optional) Configure DPDK as a shared library @@ -583,7 +583,7 @@ Limitations The latest list of validated firmware versions can be found in the `DPDK release notes`_. -.. _DPDK release notes: http://dpdk.org/doc/guides/rel_notes/release_17_05.html +.. _DPDK release notes: http://dpdk.org/doc/guides/rel_notes/release_17_11.html Reporting Bugs -------------- diff --git a/Documentation/topics/dpdk/ring.rst b/Documentation/topics/dpdk/ring.rst index ad9d7a5..8d0ede8 100644 --- a/Documentation/topics/dpdk/ring.rst +++ b/Documentation/topics/dpdk/ring.rst @@ -77,4 +77,4 @@ DPDK. However, this functionality was removed because: - :doc:`vhost-user interfaces ` are the defacto DPDK-based path to guests -.. _DPDK documentation: https://dpdk.readthedocs.io/en/v17.05/prog_guide/ring_lib.html +.. _DPDK documentation: https://dpdk.readthedocs.io/en/v17.11/prog_guide/ring_lib.html diff --git a/Documentation/topics/dpdk/vhost-user.rst b/Documentation/topics/dpdk/vhost-user.rst index 74ac06e..5347995 100644 --- a/Documentation/topics/dpdk/vhost-user.rst +++ b/Documentation/topics/dpdk/vhost-user.rst @@ -292,9 +292,9 @@ To begin, instantiate a guest as described in :ref:`dpdk-vhost-user` or DPDK sources to VM and build DPDK:: $ cd /root/dpdk/ - $ wget http://fast.dpdk.org/rel/dpdk-17.05.2.tar.xz - $ tar xf dpdk-17.05.2.tar.xz - $ export DPDK_DIR=/root/dpdk/dpdk-stable-17.05.2 + $ wget http://fast.dpdk.org/rel/dpdk-17.11.tar.xz + $ tar xf dpdk-17.11.tar.xz + $ export DPDK_DIR=/root/dpdk/dpdk-17.11 $ export DPDK_TARGET=x86_64-native-linuxapp-gcc $ export DPDK_BUILD=$DPDK_DIR/$DPDK_TARGET $ cd $DPDK_DIR @@ -378,7 +378,7 @@ Sample XML - + diff --git a/NEWS b/NEWS index 427c8f8..d4a1c9a 100644 --- a/NEWS +++ b/NEWS @@ -13,6 +13,8 @@ Post-v2.8.0 * ovn-ctl: New commands run_nb_ovsdb and run_sb_ovsdb. - Linux kernel 4.13 * Add support for compiling OVS with the latest Linux 4.13 kernel + - DPDK: + * Add support for DPDK v17.11 v2.8.0 - 31 Aug 2017 -------------------- diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c index faff842..f552444 100644 --- a/lib/netdev-dpdk.c +++ b/lib/netdev-dpdk.c @@ -26,6 +26,7 @@ #include #include +#include #include #include #include @@ -140,8 +141,8 @@ static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(5, 20); #define DPDK_ETH_PORT_ID_INVALID RTE_MAX_ETHPORTS -/* DPDK library uses uint8_t for port_id. */ -typedef uint8_t dpdk_port_t; +/* DPDK library uses uint16_t for port_id. */ +typedef uint16_t dpdk_port_t; #define VHOST_ENQ_RETRY_NUM 8 #define IF_NAME_SZ (PATH_MAX > IFNAMSIZ ? PATH_MAX : IFNAMSIZ)