From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 0F713E72 for ; Fri, 18 Sep 2015 14:42:47 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP; 18 Sep 2015 05:42:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.17,552,1437462000"; d="scan'208";a="807373070" Received: from kmsmsx154.gar.corp.intel.com ([172.21.73.14]) by orsmga002.jf.intel.com with ESMTP; 18 Sep 2015 05:42:45 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by KMSMSX154.gar.corp.intel.com (172.21.73.14) with Microsoft SMTP Server (TLS) id 14.3.224.2; Fri, 18 Sep 2015 20:42:44 +0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.110]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.12]) with mapi id 14.03.0248.002; Fri, 18 Sep 2015 20:42:43 +0800 From: "Liu, Yong" To: "Fan, ChangruX" , "dts@dpdk.org" Thread-Topic: [dts] [PATCH] Fix checksum_checking failed issue Thread-Index: AQHQ8SkLhK4FQl/AGkWhEjI3nbiZOp5CPKmg Date: Fri, 18 Sep 2015 12:42:42 +0000 Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E10EF731C@SHSMSX103.ccr.corp.intel.com> References: <1442480833-42991-1-git-send-email-changrux.fan@intel.com> In-Reply-To: <1442480833-42991-1-git-send-email-changrux.fan@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: 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] Fix checksum_checking failed issue 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: , X-List-Received-Date: Fri, 18 Sep 2015 12:42:48 -0000 Thanks. Applied. > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of changru > Sent: Thursday, September 17, 2015 5:07 PM > To: dts@dpdk.org > Subject: [dts] [PATCH] Fix checksum_checking failed issue >=20 > In UDP packet, if the chksum is equal to 0, it means the receiver don't > need to check. > But, we want to send a packet with an error checksum. > On the other hand, on 1G NICs, the packet received has the same length > with the packet sent. >=20 > Signed-off-by: changru > --- > tests/TestSuite_pmd.py | 10 +++++++--- > 1 file changed, 7 insertions(+), 3 deletions(-) >=20 > diff --git a/tests/TestSuite_pmd.py b/tests/TestSuite_pmd.py > index afb2450..525ed02 100644 > --- a/tests/TestSuite_pmd.py > +++ b/tests/TestSuite_pmd.py > @@ -375,7 +375,7 @@ class TestPmd(TestCase,IxiaPacketGenerator): >=20 > checksum =3D '' > if checksum_test: > - checksum =3D 'chksum=3D0x0' > + checksum =3D 'chksum=3D0x1' >=20 > self.tester.scapy_foreground() > self.tester.scapy_append('nutmac=3D"%s"' % mac) > @@ -402,8 +402,12 @@ class TestPmd(TestCase,IxiaPacketGenerator): > "packet pass assert error, %d RX packets, %d TX > packets" % (p1rx_pkts, p0tx_pkts)) >=20 > if checksum_test: > - self.verify(p1rx_bytes =3D=3D frame_size - 4, > - "packet pass assert error, expected %d RX bytes, > actual %d" % (frame_size - 4, p1rx_bytes)) > + if self.nic in ["powerville", "springville", "kawela_4"]: > + self.verify(p1rx_bytes =3D=3D frame_size, > + "packet pass assert error, expected %d RX > bytes, actual %d" % (frame_size, p1rx_bytes)) > + else: > + self.verify(p1rx_bytes =3D=3D frame_size - 4, > + "packet pass assert error, expected %d RX > bytes, actual %d" % (frame_size - 4, p1rx_bytes)) > else: > self.verify(p1rx_bytes =3D=3D frame_size, > "packet pass assert error, expected %d RX bytes, > actual %d" % (frame_size, p1rx_bytes)) > -- > 2.1.0