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 9D668A0524; Tue, 25 Feb 2020 02:31:13 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 886891BE85; Tue, 25 Feb 2020 02:31:13 +0100 (CET) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id 040B22C39 for ; Tue, 25 Feb 2020 02:31:11 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 24 Feb 2020 17:31:11 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,482,1574150400"; d="scan'208";a="226184554" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga007.jf.intel.com with ESMTP; 24 Feb 2020 17:31:10 -0800 Received: from fmsmsx121.amr.corp.intel.com (10.18.125.36) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 24 Feb 2020 17:31:10 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by fmsmsx121.amr.corp.intel.com (10.18.125.36) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 24 Feb 2020 17:31:10 -0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.222]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.201]) with mapi id 14.03.0439.000; Tue, 25 Feb 2020 09:31:07 +0800 From: "Tu, Lijuan" To: "Min, JiaqiX" , "dts@dpdk.org" CC: "Min, JiaqiX" Thread-Topic: [dts] [PATCH V1] tests/vf_macfilter: update vf macfilter Thread-Index: AQHV6s8Ncyo7OWDqPkqp0rSKuOl4x6grINww Date: Tue, 25 Feb 2020 01:31:07 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BBCDBE9@SHSMSX101.ccr.corp.intel.com> References: <20200224043904.54140-1-jiaqix.min@intel.com> In-Reply-To: <20200224043904.54140-1-jiaqix.min@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-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/vf_macfilter: update vf macfilter 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 Jiaqi Min > Sent: Monday, February 24, 2020 12:39 PM > To: dts@dpdk.org > Cc: Min, JiaqiX > Subject: [dts] [PATCH V1] tests/vf_macfilter: update vf macfilter >=20 > support for add and remove vf mac address in ixgbe >=20 > Signed-off-by: Jiaqi Min > --- > tests/TestSuite_vf_macfilter.py | 20 +++++++++++++++++--- > 1 file changed, 17 insertions(+), 3 deletions(-) >=20 > diff --git a/tests/TestSuite_vf_macfilter.py b/tests/TestSuite_vf_macfilt= er.py > index fe64f44..dc30059 100644 > --- a/tests/TestSuite_vf_macfilter.py > +++ b/tests/TestSuite_vf_macfilter.py > @@ -192,7 +192,10 @@ class TestVfMacFilter(TestCase): > What's more, send packets with a wrong MAC address to the VF, ch= eck > the VF will not RX packets. > """ > - self.verify(self.nic.startswith('fortville') =3D=3D True, "NIC i= s [%s], skip this > case" %self.nic) > + if 'niantic' =3D=3D self.nic: > + self.verify(self.nic.startswith('niantic') =3D=3D True, "NIC= is [%s], skip this > case" %self.nic) > + else: > + self.verify(self.nic.startswith('fortville') =3D=3D True, "N= IC > + is [%s], skip this case" %self.nic) > self.setup_2pf_2vf_1vm_env(False,driver=3D'igb_uio') > self.send_packet_and_verify() >=20 > @@ -245,13 +248,24 @@ class TestVfMacFilter(TestCase): > print("\nshow port stats in testpmd for double check: \n", > self.vm0_testpmd.execute_cmd('show port stats all')) > self.verify(result2 !=3D False, "VF0 failed to forward packets t= o VF1") >=20 > - print("\nThirdly, negative test, send packets to a wrong MAC, ex= pected > result is RX packets=3D0\n") > - dst_mac =3D self.vf0_wrongmac > + print ("\Thirdly, remove the added mac address then send packets= to > the deleted MAC, expected result is RX packets=3D0\n") > + ret =3D self.vm0_testpmd.execute_cmd('mac_addr remove > 0 %s' %self.vf0_setmac) > + # check the operation is supported or not. > + print (ret) > + > + dst_mac =3D self.vf0_setmac > pkt_param=3D[("ether", {'dst': dst_mac, 'src': src_mac})] > result3 =3D self.tester.check_random_pkts(tgen_ports, pktnum=3D1= 00, > allow_miss=3DFalse, params=3Dpkt_param) > print("\nshow port stats in testpmd for double check: \n", > self.vm0_testpmd.execute_cmd('show port stats all')) > self.verify(result3 !=3D True, "VF0 failed to forward packets to= VF1") >=20 > + print ("\nFourthly, negative test, send packets to a wrong MAC, > expected result is RX packets=3D0\n") > + dst_mac =3D self.vf0_wrongmac > + pkt_param=3D[("ether", {'dst': dst_mac, 'src': src_mac})] > + result4 =3D self.tester.check_random_pkts(tgen_ports, pktnum=3D1= 00, > allow_miss=3DFalse, params=3Dpkt_param) > + print ("\nshow port stats in testpmd for double check: %s\n" % > self.vm0_testpmd.execute_cmd('show port stats all')) > + self.verify(result4 !=3D True, "VF0 failed to forward packets to > + VF1") > + >=20 > def tear_down(self): >=20 > -- > 2.17.1