From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Rybchenko Subject: Re: [PATCH 1/2] app/testpmd: add commands to test new Rx offload API Date: Mon, 12 Mar 2018 11:42:39 +0300 Message-ID: References: <1520842543-46810-1-git-send-email-wei.dai@intel.com> <1520842543-46810-2-git-send-email-wei.dai@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Cc: To: Wei Dai , , 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) In-Reply-To: <1520842543-46810-2-git-send-email-wei.dai@intel.com> Content-Language: en-GB List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 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.