From patchwork Mon Jan 13 15:48:29 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ciara Loftus X-Patchwork-Id: 1222184 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.133; helo=hemlock.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=intel.com Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47xJ0q2Sshz9sP6 for ; Tue, 14 Jan 2020 02:48:58 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 1945386632; Mon, 13 Jan 2020 15:48:57 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6rQIgvldAM3s; Mon, 13 Jan 2020 15:48:55 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by hemlock.osuosl.org (Postfix) with ESMTP id 21BB686416; Mon, 13 Jan 2020 15:48:55 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0D67AC1D80; Mon, 13 Jan 2020 15:48:55 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by lists.linuxfoundation.org (Postfix) with ESMTP id 6C4B2C077D for ; Mon, 13 Jan 2020 15:48:54 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 535CD813FF for ; Mon, 13 Jan 2020 15:48:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Vf0lVOWpM+kI for ; Mon, 13 Jan 2020 15:48:53 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by whitealder.osuosl.org (Postfix) with ESMTPS id 85CF0810C1 for ; Mon, 13 Jan 2020 15:48:53 +0000 (UTC) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 13 Jan 2020 07:48:52 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,429,1571727600"; d="scan'208";a="247738611" Received: from silpixa00399839.ir.intel.com (HELO silpixa00399839.ger.corp.intel.com) ([10.237.223.27]) by fmsmga004.fm.intel.com with ESMTP; 13 Jan 2020 07:48:51 -0800 From: Ciara Loftus To: dev@openvswitch.org, fbl@sysclose.org, ian.stokes@intel.com Date: Mon, 13 Jan 2020 15:48:29 +0000 Message-Id: <20200113154829.70855-1-ciara.loftus@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [ovs-dev] [PATCH] Documentation: add notes for TSO & i40e 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" When using TSO in OVS-DPDK with an i40e device, the following commit is required for DPDK, which fixes an issue on the TSO path: http://git.dpdk.org/next/dpdk-next-net/commit/?id=b2a4dc260139409c539fb8e7f1b9d0a5182cfd2b Document this as a limitation until a DPDK release with the fix included is supported by OVS. Also, document best known methods for performance tuning when testing TSO with the tool iperf. Signed-off-by: Ciara Loftus Acked-by: Flavio Leitner --- Documentation/topics/dpdk/tso.rst | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/Documentation/topics/dpdk/tso.rst b/Documentation/topics/dpdk/tso.rst index 189c86480..5c56c458c 100644 --- a/Documentation/topics/dpdk/tso.rst +++ b/Documentation/topics/dpdk/tso.rst @@ -94,3 +94,30 @@ datapath must support TSO or packets using that feature will be dropped on ports without TSO support. That also means guests using vhost-user in client mode will receive TSO packet regardless of TSO being enabled or disabled within the guest. + +When the NIC performing the segmentation is using the i40e DPDK PMD, a fix +must be included in the DPDK build, otherwise TSO will not work. The fix can +be found on `the dpdk.org net-next tree`__. + +__ http://git.dpdk.org/next/dpdk-next-net/commit/?id=e975e3720ba16278c6b43f8938b75710573bbd6a + +This fix is expected to be included in the 19.11.1 release. When OVS migrates +to this DPDK release, this limitation can be removed. + +~~~~~~~~~~~~~~~~~~ +Performance Tuning +~~~~~~~~~~~~~~~~~~ + +iperf is often used to test TSO performance. Care needs to be taken when +configuring the environment in which the iperf server process is being run. +Since the iperf server uses the NIC's kernel driver, IRQs will be generated. +By default with some NICs eg. i40e, the IRQs will land on the same core as that +which is being used by the server process, provided the number of NIC queues is +greater or equal to that lcoreid. This causes contention between the iperf +server process and the IRQs. For optimal performance, it is suggested to pin +the IRQs to their own core. To change the affinity associated with a given IRQ +number, you can 'echo' the desired coremask to the file +/proc/irq//smp_affinity +For more on SMP affinity, refer to the `Linux kernel documentation`__. + +__ https://www.kernel.org/doc/Documentation/IRQ-affinity.txt