From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 38E3BA00E6 for ; Wed, 7 Aug 2019 04:23:52 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2C7CE5424; Wed, 7 Aug 2019 04:23:52 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id A88E44C97 for ; Wed, 7 Aug 2019 04:23:50 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 06 Aug 2019 19:23:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,353,1559545200"; d="scan'208";a="373616692" Received: from fmsmsx103.amr.corp.intel.com ([10.18.124.201]) by fmsmga005.fm.intel.com with ESMTP; 06 Aug 2019 19:23:49 -0700 Received: from fmsmsx114.amr.corp.intel.com (10.18.116.8) by FMSMSX103.amr.corp.intel.com (10.18.124.201) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 6 Aug 2019 19:23:49 -0700 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by FMSMSX114.amr.corp.intel.com (10.18.116.8) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 6 Aug 2019 19:23:49 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.80]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.62]) with mapi id 14.03.0439.000; Wed, 7 Aug 2019 10:23:47 +0800 From: "Tu, Lijuan" To: "Li, WenjieX A" , "dts@dpdk.org" CC: "Li, WenjieX A" Thread-Topic: [dts] [PATCH V1] tests/userspace_ethtool: optimze port_mtu for springville/powerville Thread-Index: AQHVOvG/Av50+5IeCkKELR2ioJXS+6bvGFng Date: Wed, 7 Aug 2019 02:23:46 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BAFEAF1@SHSMSX101.ccr.corp.intel.com> References: <1563215869-27837-1-git-send-email-wenjiex.a.li@intel.com> In-Reply-To: <1563215869-27837-1-git-send-email-wenjiex.a.li@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.2.0.6 dlp-reaction: no-action x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZTg1ZTE1OWQtNjgzYy00MzU1LWIwMmYtZTkyMjZjMDQwMzJjIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiV2k2a2N3Z29sWFBjVlZyYTd3Z1RtakxkaHBXR1p3ZVJlK3ZkbHNRMDJCSDcrUW8yakRUTTRHbHNlMFBHeDZrMiJ9 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 V1] tests/userspace_ethtool: optimze port_mtu for springville/powerville 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 Wenjie Li > Sent: Tuesday, July 16, 2019 2:38 AM > To: dts@dpdk.org > Cc: Li, WenjieX A > Subject: [dts] [PATCH V1] tests/userspace_ethtool: optimze port_mtu for > springville/powerville >=20 > 1. From DPDK-15062, max mtu of igb NIC is 2026; change mtu_threshold to > 2026 for powerville and springville in script. > 2. The ether headsize is 22 bytes(not 18) in igb nics; add an offset(4 by= tes) > for the packets. >=20 > Signed-off-by: Wenjie Li > --- > tests/TestSuite_userspace_ethtool.py | 11 +++++++++-- > 1 file changed, 9 insertions(+), 2 deletions(-) >=20 > diff --git a/tests/TestSuite_userspace_ethtool.py > b/tests/TestSuite_userspace_ethtool.py > index c774552..afd5d00 100644 > --- a/tests/TestSuite_userspace_ethtool.py > +++ b/tests/TestSuite_userspace_ethtool.py > @@ -548,6 +548,10 @@ class TestUserspaceEthtool(TestCase, > IxiaPacketGenerator): > self.dut.send_expect(self.cmd, "EthApp>", 60) > mtus =3D [1519, 2048] > mtu_threshold =3D 2022 > + offset =3D 0 > + if self.nic in ['powerville', 'springville']: > + mtu_threshold =3D 2026 > + offset =3D 4 > for index in range(len(self.ports)): > port =3D self.ports[index] > # change mtu > @@ -558,17 +562,20 @@ class TestUserspaceEthtool(TestCase, > IxiaPacketGenerator): > for mtu in mtus: > # The mtu threshold is 2022,When it is greater than 2022= , the > open/stop port is required. > if mtu > mtu_threshold: > + if self.nic in ['powerville', 'springville']: > + mtu =3D mtu_threshold > self.dut.send_expect("stop %s" % index, "EthApp>") > self.dut.send_expect("mtu %d %d" % (index, mtu), "Et= hApp>") > self.dut.send_expect("open %s" % index, "EthApp>") > self.dut.send_expect("mtu %d %d" % (index, mtu), "EthApp= >") > + time.sleep(5) > ori_rx_pkts, _ =3D self.strip_portstats(index) > - pkt_size =3D mtu + HEADER_SIZE['eth'] > + pkt_size =3D mtu + HEADER_SIZE['eth'] + offset > pkt =3D Packet(pkt_len=3Dpkt_size) > pkt.send_pkt(tx_port=3Dintf, count=3D4) > rx_pkts, _ =3D self.strip_portstats(index) > self.verify(rx_pkts =3D=3D ori_rx_pkts + 4, "Packet matc= h mtu not > forwarded as expected") > - pkt =3D Packet(pkt_len=3Dmtu + 1 + HEADER_SIZE['eth']) > + pkt =3D Packet(pkt_len=3Dmtu + 1 + HEADER_SIZE['eth'] + > + offset) > pkt.send_pkt(tx_port=3Dintf, count=3D4) > rx_pkts_over, _ =3D self.strip_portstats(index) > self.verify(rx_pkts =3D=3D rx_pkts_over, "Packet over mt= u should not be > forwarded") > -- > 2.17.1