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 7E6102C6A for ; Mon, 14 Mar 2016 09:11:11 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP; 14 Mar 2016 01:11:10 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,334,1455004800"; d="scan'208";a="933221359" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga002.jf.intel.com with ESMTP; 14 Mar 2016 01:11:11 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.248.2; Mon, 14 Mar 2016 01:11:09 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.24]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.18]) with mapi id 14.03.0248.002; Mon, 14 Mar 2016 16:11:08 +0800 From: "Liu, Yong" To: "Tu, LijuanX A" , "dts@dpdk.org" Thread-Topic: [dts][PATCH v3]tests vf_vlan: update vm cases Thread-Index: AQHRfa9ZKkaYUoccn0aTOmo4OM7Vv59YlrWg Date: Mon, 14 Mar 2016 08:11:08 +0000 Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E14EC36F2@SHSMSX103.ccr.corp.intel.com> References: <1457931755-88403-1-git-send-email-lijuanx.a.tu@intel.com> In-Reply-To: <1457931755-88403-1-git-send-email-lijuanx.a.tu@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiODZmZjgyNTItYmU0MS00MmE5LTljZDQtNzlhYWExOTNhMjYwIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6ImQyMVVmclZFSERlMms1OWJjbWtSYzU3TDh2YmtZK3Y2aEpqbHFoWTZYbGM9In0= x-ctpclassification: CTP_IC 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 v3]tests vf_vlan: update vm cases 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: Mon, 14 Mar 2016 08:11:12 -0000 Applied. Thanks. > -----Original Message----- > From: Tu, LijuanX A > Sent: Monday, March 14, 2016 1:03 PM > To: Liu, Yong; dts@dpdk.org > Cc: Tu, LijuanX A > Subject: [dts][PATCH v3]tests vf_vlan: update vm cases >=20 > 1. stop forwarding and then can start again > 2. for fortville ,"enabletx_vlan" must "enable rx_vlan" at same time > 3. a little time waitafter 'rx_vlan add %d 0' > 4. fix vlan set strip on/off in for-cycle >=20 > Signed-off-by: Lijuan Tu > --- > tests/TestSuite_vf_vlan.py | 14 +++++++++++--- > 1 file changed, 11 insertions(+), 3 deletions(-) >=20 > diff --git a/tests/TestSuite_vf_vlan.py b/tests/TestSuite_vf_vlan.py > index 6bde6ca..0a0dbe1 100644 > --- a/tests/TestSuite_vf_vlan.py > +++ b/tests/TestSuite_vf_vlan.py > @@ -243,6 +243,7 @@ class TestVfVlan(TestCase): > inst =3D sniff_packets(self.tester_intf0, timeout=3D5) > self.vm0_testpmd.execute_cmd('set burst 1') > self.vm0_testpmd.execute_cmd('start tx_first') > + self.vm0_testpmd.execute_cmd('stop') >=20 > # strip sniffered vlans > pkts =3D load_sniff_packets(inst) > @@ -265,6 +266,11 @@ class TestVfVlan(TestCase): > self.vm0_testpmd.execute_cmd('set verbose 1') >=20 > for tx_vlan in tx_vlans: > + # for fortville , > + # if you want insert tx_vlan, > + # please enable rx_vlan at the same time > + if self.kdriver =3D=3D "i40e": > + self.vm0_testpmd.execute_cmd('rx_vlan add %d 0' % > tx_vlan) > self.vm0_testpmd.execute_cmd('tx_vlan set 0 %d' % tx_vlan) > self.tx_and_check(tx_vlan=3Dtx_vlan) >=20 > @@ -280,7 +286,7 @@ class TestVfVlan(TestCase): > self.vm0_testpmd.start_testpmd(VM_CORES_MASK) > self.vm0_testpmd.execute_cmd('set fwd rxonly') > self.vm0_testpmd.execute_cmd('set verbose 1') > - self.vm0_testpmd.execute_cmd('vlan set strip off 0') > + self.vm0_testpmd.execute_cmd('vlan set strip on 0') > self.vm0_testpmd.execute_cmd('start') >=20 > # send packet without vlan > @@ -295,6 +301,7 @@ class TestVfVlan(TestCase): >=20 > for rx_vlan in rx_vlans: > self.vm0_testpmd.execute_cmd('rx_vlan add %d 0' % rx_vlan) > + time.sleep(1) > # send packet with same vlan > out =3D self.send_and_getout(vlan=3Drx_vlan, pkt_type=3D"VLA= N_UDP") > vlan_hex =3D hex(rx_vlan) > @@ -312,7 +319,7 @@ class TestVfVlan(TestCase): > "received 1 packets" not in out, "Received filtered vlan > packet!!!") >=20 > for rx_vlan in rx_vlans: > - self.vm0_testpmd.execute_cmd('rx_vlan rm 0 %d' % random_vlan= ) > + self.vm0_testpmd.execute_cmd('rx_vlan rm 0 %d' % rx_vlan) >=20 > # send packet with vlan 0 > out =3D self.send_and_getout(vlan=3D0, pkt_type=3D"VLAN_UDP") > @@ -341,11 +348,12 @@ class TestVfVlan(TestCase): > self.vm0_testpmd.start_testpmd(VM_CORES_MASK) > self.vm0_testpmd.execute_cmd('set fwd rxonly') > self.vm0_testpmd.execute_cmd('set verbose 1') > - self.vm0_testpmd.execute_cmd('vlan set strip on 0') > self.vm0_testpmd.execute_cmd('start') >=20 > for rx_vlan in rx_vlans: > + self.vm0_testpmd.execute_cmd('vlan set strip on 0') > self.vm0_testpmd.execute_cmd('rx_vlan add %d 0' % rx_vlan) > + time.sleep(1) > out =3D self.send_and_getout(vlan=3Drx_vlan, pkt_type=3D"VLA= N_UDP") > # enable strip, vlan will be in mbuf > vlan_hex =3D hex(rx_vlan) > -- > 1.9.3