From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id 536164CC0 for ; Mon, 12 Mar 2018 09:42:49 +0100 (CET) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1-us4.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 217F0140059; Mon, 12 Mar 2018 08:42:48 +0000 (UTC) Received: from [192.168.38.17] (84.52.114.114) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Mon, 12 Mar 2018 08:42:43 +0000 To: Wei Dai , , CC: References: <1520842543-46810-1-git-send-email-wei.dai@intel.com> <1520842543-46810-2-git-send-email-wei.dai@intel.com> From: Andrew Rybchenko Message-ID: Date: Mon, 12 Mar 2018 11:42:39 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <1520842543-46810-2-git-send-email-wei.dai@intel.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-GB X-Originating-IP: [84.52.114.114] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-11.0.0.1191-8.100.1062-23714.003 X-TM-AS-Result: No--13.741700-0.000000-31 X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-MDID: 1520844168-DS+Ec+G+vOG3 Subject: Re: [dpdk-dev] [PATCH 1/2] app/testpmd: add commands to test new Rx offload API 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: , X-List-Received-Date: Mon, 12 Mar 2018 08:42:49 -0000 On 03/12/2018 11:15 AM, Wei Dai wrote: > Add following testpmd run-time commands to support test of > new Rx offload API: > rx_offload get capability > rx_offload get configuration > rx_offload enable|disable per_port vlan_strip|ipv4_cksum... > rx_offload enable|disable per_queue vlan_strip|iipv4_cksum... > > > Above last 2 commands should be run when the port is stopped. > > Signed-off-by: Wei Dai > --- > app/test-pmd/cmdline.c | 456 +++++++++++++++++++++++++++++++++++++++++++++++++ > app/test-pmd/testpmd.c | 15 +- > app/test-pmd/testpmd.h | 1 + > 3 files changed, 470 insertions(+), 2 deletions(-) > > diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c > index d1dc1de..1a08b3d 100644 > --- a/app/test-pmd/cmdline.c > +++ b/app/test-pmd/cmdline.c > @@ -15996,6 +15996,458 @@ cmdline_parse_inst_t cmd_ptype_mapping_update = { > }, > }; > > +static const char * const rx_offload_names[] = { > + "VLAN_STRIP", > + "IPV4_CKSUM", > + "UDP_CKSUM", > + "TCP_CKSUM", > + "TCP_LRO", > + "QINQ_STRIP", > + "OUTER_IPV4_CKSUM", > + "MACSEC_STRIP", > + "HEADER_SPLIT", > + "VLAN_FILTER", > + "VLAN_EXTEND", > + "JUMBO_FRAME", > + "CRC_STRIP", > + "SCATTER", > + "TIMESTAMP", > + "SECURITY" > +}; There are already rte_rx_offload_names in librte_ethdev/rte_ethdev.c and rte_eth_dev_rx_offload_name() function in API.