From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id B4BECA00E6 for ; Fri, 17 May 2019 04:00:35 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 54467326C; Fri, 17 May 2019 04:00:35 +0200 (CEST) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id 80CE52BF2 for ; Fri, 17 May 2019 04:00:31 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 16 May 2019 19:00:29 -0700 X-ExtLoop1: 1 Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by fmsmga007.fm.intel.com with ESMTP; 16 May 2019 19:00:29 -0700 Received: from fmsmsx120.amr.corp.intel.com (10.18.124.208) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 16 May 2019 19:00:29 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by fmsmsx120.amr.corp.intel.com (10.18.124.208) with Microsoft SMTP Server (TLS) id 14.3.408.0; Thu, 16 May 2019 19:00:28 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.129]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.216]) with mapi id 14.03.0415.000; Fri, 17 May 2019 10:00:26 +0800 From: "Tu, Lijuan" To: "Peng, Yuan" , "dts@dpdk.org" CC: "Peng, Yuan" Thread-Topic: [dts] [PATCH]test_plans: add tx checksum case to rxtx_offload_test_plan.rst Thread-Index: AQHVBuy4Ala2CDreikmmfQ+fNkmkjqZumrVw Date: Fri, 17 May 2019 02:00:26 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BA8252C@SHSMSX101.ccr.corp.intel.com> References: <1557464427-38853-1-git-send-email-yuan.peng@intel.com> In-Reply-To: <1557464427-38853-1-git-send-email-yuan.peng@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.600.7 dlp-reaction: no-action x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMjE0MDNmZGUtNDUwYi00YjE1LWEyZTUtNDE0MjFkMTAzODA0IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTWRXVkdhd2Y4ZG1NUWpRWTZNeEcxOE1rSzNVdGl4ZXNtQ3hoQko5S0N6clpVTmtKZENZYUJ2ZFF4SXI2Y1A2cCJ9 x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dts] [PATCH]test_plans: add tx checksum case to rxtx_offload_test_plan.rst X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" Applied, thanks > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Peng Yuan > Sent: Friday, May 10, 2019 1:00 PM > To: dts@dpdk.org > Cc: Peng, Yuan > Subject: [dts] [PATCH]test_plans: add tx checksum case to > rxtx_offload_test_plan.rst >=20 > Add tx checksum case to rxtx_offload_test_plan.rst >=20 > Signed-off-by: Peng Yuan >=20 > diff --git a/test_plans/rxtx_offload_test_plan.rst > b/test_plans/rxtx_offload_test_plan.rst > index 8b08682..246e1e1 100644 > --- a/test_plans/rxtx_offload_test_plan.rst > +++ b/test_plans/rxtx_offload_test_plan.rst > @@ -193,6 +193,8 @@ Test case: Rx offload per-port setting in command- > line 1. Enable rx cksum in command-line:: >=20 > ./testpmd -c f -n 4 -- -i --rxq=3D4 --txq=3D4 --enable-rx-cksum > + testpmd> set fwd csum > + testpmd> set verbose 1 > testpmd> show port 0 rx_offload configuration > Rx Offloading Configuration of port 0 : > Port : IPV4_CKSUM UDP_CKSUM TCP_CKSUM @@ -201,6 +203,20 @@ > Test case: Rx offload per-port setting in command-line > Queue[ 2] : > Queue[ 3] : >=20 > +1) Send packets:: > + > + pkt1=3DEther(dst=3D"00:00:00:00:01:00", > src=3D"52:00:00:00:00:00")/IP(src=3D"10.0.0.1")/TCP()/("X"*46) > + pkt2=3DEther(dst=3D"00:00:00:00:01:00", > src=3D"52:00:00:00:00:00")/IP(chksum=3D0x0)/TCP(chksum=3D0xf)/("X"*46) > + pkt3=3DEther(dst=3D"00:00:00:00:01:00", > src=3D"52:00:00:00:00:00")/IP(src=3D"10.0.0.1")/UDP(chksum=3D0xf)/("X"*46= ) > + pkt4=3DEther(dst=3D"00:00:00:00:01:00", > + src=3D"52:00:00:00:00:00")/IP(chksum=3D0x0)/UDP()/("X"*46) > + > +2) Check the rx flags:: > + > + PKT_RX_L4_CKSUM_GOOD PKT_RX_IP_CKSUM_GOOD > + PKT_RX_L4_CKSUM_BAD PKT_RX_IP_CKSUM_BAD > + PKT_RX_L4_CKSUM_BAD PKT_RX_IP_CKSUM_GOOD > + PKT_RX_L4_CKSUM_UNKNOWN PKT_RX_IP_CKSUM_BAD > + > 2. Disable the rx cksum per_port:: >=20 > testpmd> port stop 0 > @@ -504,6 +520,68 @@ Test case: Tx offload per-port setting in command- > line > The tester port received packets with vlan ID. > The per_port capability can be enabled by per_port command. >=20 > +Test case: Tx offload checksum > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D > + > +1. Set checksum forward mode:: > + > + ./testpmd -c f -n 4 -- -i --rxq=3D4 --txq=3D4 > + testpmd> set fwd csum > + testpmd> set verbose 1 > + testpmd> show port 0 tx_offload configuration > + Rx Offloading Configuration of port 0 : > + Port : > + Queue[ 0] : > + Queue[ 1] : > + Queue[ 2] : > + Queue[ 3] : > + > +1) Send an ipv4-udp packet to the port:: > + > + sendp([Ether(dst=3D"00:00:00:00:01:00")/IP(src=3D"100.0.0.1", > + dst=3D"100.0.0.2")/UDP(sport=3D1024,dport=3D1025)], iface=3D"enp131s0f3= ") > + > +2) Check the tx flags:: > + > + PKT_TX_L4_NO_CKSUM PKT_TX_IPV4 > + > +2. Enable the tx ipv4_cksum of port 1:: > + > + testpmd> port stop 1 > + testpmd> port config 1 tx_offload ipv4_cksum on > + testpmd> show port 1 tx_offload configuration > + Tx Offloading Configuration of port 1 : > + Port : IPV4_CKSUM > + Queue[ 0] : IPV4_CKSUM > + Queue[ 1] : IPV4_CKSUM > + Queue[ 2] : IPV4_CKSUM > + Queue[ 3] : IPV4_CKSUM > + testpmd> port start 1 > + testpmd> start > + > + The port can start normally. > + > +3. Send an ipv4-udp packet to the port:: > + > + sendp([Ether(dst=3D"00:00:00:00:01:00")/IP(src=3D"100.0.0.1", > + dst=3D"100.0.0.2")/UDP(sport=3D1024,dport=3D1025)], iface=3D"enp131s0f3= ") > + > + There is printing "PKT_TX_IP_CKSUM" and "PKT_TX_L4_NO_CKSUM" in the > tx line. > + > +4. Disable tx ipv4_cksum and enable tx udp_cksum, > + then send the same ipv4-udp packet, there is printing > "PKT_TX_UDP_CKSUM", > + but no "PKT_TX_IP_CKSUM". > + > +5. Try step 4 with "tcp_cksum" on, then send an ipv4-tcp packet:: > + > + sendp([Ether(dst=3D"00:00:00:00:01:00")/IP(src=3D"100.0.0.1", > + dst=3D"100.0.0.2")/TCP(sport=3D1024,dport=3D1025)], iface=3D"enp131s0f3= ") > + > + There is printing "PKT_TX_TCP_CKSUM". > + > +6. Try step 4 with "sctp_cksum" on, then send an ipv4-sctp packet:: > + > + sendp([Ether(dst=3D"00:00:00:00:01:00")/IP(src=3D"100.0.0.1", > + dst=3D"100.0.0.2")/sctp(sport=3D1024,dport=3D1025)], iface=3D"enp131s0f= 3") > + > + There is printing "PKT_TX_SCTP_CKSUM". > + > Test case: Tx offload per-queue and per-port setting > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >=20 > -- > 2.14.3