From patchwork Wed Feb 22 16:09:59 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shahaf Shuler X-Patchwork-Id: 20671 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 4879258EC; Wed, 22 Feb 2017 17:10:49 +0100 (CET) Received: from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129]) by dpdk.org (Postfix) with ESMTP id 901B95598 for ; Wed, 22 Feb 2017 17:10:22 +0100 (CET) Received: from Internal Mail-Server by MTLPINE1 (envelope-from shahafs@mellanox.com) with ESMTPS (AES256-SHA encrypted); 22 Feb 2017 18:10:20 +0200 Received: from arch009.mtl.labs.mlnx (arch009.mtl.labs.mlnx [10.7.12.209]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id v1MGAJhV008224; Wed, 22 Feb 2017 18:10:19 +0200 Received: from arch009.mtl.labs.mlnx (localhost [127.0.0.1]) by arch009.mtl.labs.mlnx (8.14.7/8.14.7) with ESMTP id v1MGAJNj046836; Wed, 22 Feb 2017 18:10:19 +0200 Received: (from root@localhost) by arch009.mtl.labs.mlnx (8.14.7/8.14.7/Submit) id v1MGAJxQ046835; Wed, 22 Feb 2017 18:10:19 +0200 From: Shahaf Shuler To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com, thomas.monjalon@6wind.com, jingjing.wu@intel.com Cc: dev@dpdk.org Date: Wed, 22 Feb 2017 18:09:59 +0200 Message-Id: <1487779800-46491-4-git-send-email-shahafs@mellanox.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1487779800-46491-1-git-send-email-shahafs@mellanox.com> References: <1487779800-46491-1-git-send-email-shahafs@mellanox.com> Subject: [dpdk-dev] [PATCH 3/4] app/testpmd: add TSO disable to test options X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Add the option to globaly disable hardware TSO offload from the command line. Signed-off-by: Shahaf Shuler --- app/test-pmd/parameters.c | 9 ++++++++- doc/guides/testpmd_app_ug/run_app.rst | 4 ++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c index 28db8cd..7cd88bc 100644 --- a/app/test-pmd/parameters.c +++ b/app/test-pmd/parameters.c @@ -196,6 +196,7 @@ " or total packet length.\n"); printf(" --disable-link-check: disable check on link status when " "starting/stopping ports.\n"); + printf(" --disable-tso: disable hardware TCP segmentation offload.\n"); } #ifdef RTE_LIBRTE_CMDLINE @@ -561,6 +562,7 @@ { "no-flush-rx", 0, 0, 0 }, { "txpkts", 1, 0, 0 }, { "disable-link-check", 0, 0, 0 }, + { "disable-tso", 0, 0, 0 }, { 0, 0, 0, 0 }, }; @@ -978,7 +980,12 @@ no_flush_rx = 1; if (!strcmp(lgopts[opt_idx].name, "disable-link-check")) no_link_check = 1; - + if (!strcmp(lgopts[opt_idx].name, "disable-tso")) { + if (txq_flags < 0) + txq_flags = ETH_TXQ_FLAGS_NOTSOOFFL; + else + txq_flags |= ETH_TXQ_FLAGS_NOTSOOFFL; + } break; case 'h': usage(argv[0]); diff --git a/doc/guides/testpmd_app_ug/run_app.rst b/doc/guides/testpmd_app_ug/run_app.rst index 38a4025..58417ea 100644 --- a/doc/guides/testpmd_app_ug/run_app.rst +++ b/doc/guides/testpmd_app_ug/run_app.rst @@ -460,3 +460,7 @@ The commandline options are: * ``--disable-link-check`` Disable check on link status when starting/stopping ports. + +* ``--disable-tso`` + + Disable hardware TCP segmentation offload.