test suite reviews and discussions
 help / color / mirror / Atom feed
From: "Liu, Yong" <yong.liu@intel.com>
To: "Qiu, Michael" <michael.qiu@intel.com>, "dts@dpdk.org" <dts@dpdk.org>
Subject: Re: [dts] [PATCH] TSO: Add RRC support and some bug fix
Date: Wed, 04 Nov 2015 14:53:38 +0800	[thread overview]
Message-ID: <5639AB72.1040509@intel.com> (raw)
In-Reply-To: <533710CFB86FA344BFBF2D6802E6028621B658D5@SHSMSX101.ccr.corp.intel.com>

Sure, but i still has few questions in the suite.

On 11/04/2015 02:24 PM, Qiu, Michael wrote:
> Hi, Marvin
>
> I will update dpdk_test_case_checklist.xls in one patch, so would you
> please merge this first?
>
> Thanks,
> Michael
> On 2015/10/14 16:30, Liu, Yong wrote:
>> Hi Michael,
>> For those case not supported RRC, you can add them into dpdk_test_case_checklist.xls just in conf folder.
>>
>>
>>> -----Original Message-----
>>> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Michael Qiu
>>> Sent: Wednesday, October 14, 2015 9:18 AM
>>> To: dts@dpdk.org
>>> Subject: [dts] [PATCH] TSO: Add RRC support and some bug fix
>>>
>>> Add RRC support and some bug fix.
>>>
>>> Signed-off-by: Mihcael Qiu <michael.qiu@intel.com>
>>> ---
>>>   tests/TestSuite_tso.py | 37 +++++++++++++++++++++----------------
>>>   1 file changed, 21 insertions(+), 16 deletions(-)
>>>
>>> diff --git a/tests/TestSuite_tso.py b/tests/TestSuite_tso.py
>>> index 392157f..c3a13ee 100644
>>> --- a/tests/TestSuite_tso.py
>>> +++ b/tests/TestSuite_tso.py
>>> @@ -83,7 +83,8 @@ class TestTSO(TestCase):
>>>           # this feature support Fortville, Niantic
>>>           self.verify(self.nic in ["kawela_2", "niantic", "bartonhills",
>>> "82545EM",
>>>                                    "82540EM", "springfountain",
>>> "fortville_eagle",
>>> -                                 "fortville_spirit",
>>> "fortville_spirit_single"],
>>> +                                 "fortville_spirit",
>>> "fortville_spirit_single",
>>> +                                 "redrockcanyou"],
>>>                       "NIC Unsupported: " + str(self.nic))
>>>
>>>           # Based on h/w type, choose how many ports to use
>>> @@ -138,7 +139,7 @@ class TestTSO(TestCase):
>>>
>>>           for iface in ifaces:
>>>               command = ('tcpdump -w tcpdump_{0}.pcap -i {0}
>>> 2>tcpdump_{0}.out &').format(iface)
>>> -            self.tester.send_expect('rm -f tcpdump_{0}.pcap',
>>> '#').format(iface)
>>> +            self.tester.send_expect(('rm -f
>>> tcpdump_{0}.pcap').format(iface), '#')
>>>               self.tester.send_expect(command, '#')
>>>
>>>       def tcpdump_stop_sniff(self):
>>> @@ -182,7 +183,7 @@ class TestTSO(TestCase):
>>>           self.verify(cores is not None, "Insufficient cores for speed
>>> testing")
>>>           self.coreMask = dts.create_mask(cores)
>>>
>>> -        padding = self.frame_sizes[0] - self.headers_size
>>> +        padding = [self.frame_sizes[0] - self.headers_size,
>>> self.frame_sizes[1] - self.headers_size]
>>>
>>>           self.tester.send_expect("ethtool -K %s rx off tx off tso off gso
>>> off gro off lro off" % tx_interface, "# ")
>>>           self.tester.send_expect("ip l set %s up" % tx_interface, "# ")
>>> @@ -206,6 +207,7 @@ class TestTSO(TestCase):
>>>
>>>           self.dut.send_expect("tso set 800 %d" % self.dut_ports[1],
>>> "testpmd> ", 120)
>>>           self.dut.send_expect("set fwd csum", "testpmd> ", 120)
>>> +	self.dut.send_expect("set promisc all off", "testpmd> ", 120)
>>>           self.dut.send_expect("start", "testpmd> ")
>>>
>>>           self.tester.scapy_foreground()
>>> @@ -214,31 +216,34 @@ class TestTSO(TestCase):
>>>           # IPv4 tcp test
>>>
>>>           self.tcpdump_start_sniffing([tx_interface, rx_interface])
>>> -
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2")/TCP(sport=1021,dport=1021)/("X"*%s)
>>> ], iface="%s")' % (mac, padding, tx_interface))
>>> +
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2")/TCP(sport=1021,dport=1021)/("X"*%s)
>>> ], iface="%s")' % (mac, padding[0], tx_interface))
>>>           out = self.tester.scapy_execute()
>>>           out = self.dut.send_expect("show port stats all", "testpmd> ",
>>> 120)
>>>           print out
>>>           self.tcpdump_stop_sniff()
>>>           rx_stats = self.number_of_packets(rx_interface)
>>> -        if (rx_stats == 2):
>>> -            self.verify(1, "Pass")
>>> +        self.verify(rx_stats == 1, "FAIL")
>>>
>>>           # IPv6 tcp test
>>>
>>>           self.tcpdump_start_sniffing([tx_interface, rx_interface])
>>> -        self.tester.scapy_append('sendp([Ether(dst="%s",
>>> src="52:00:00:00:00:00")/IPv6(src="FE80:0:0:0:200:1FF:FE00:200",
>>> dst="3555:5555:6666:6666:7777:7777:8888:8888")/TCP(sport=1021,dport=1021)/
>>> ("X"*%s)], iface="%s")' % (mac, padding, tx_interface))
>>> +        self.tester.scapy_append('sendp([Ether(dst="%s",
>>> src="52:00:00:00:00:00")/IPv6(src="FE80:0:0:0:200:1FF:FE00:200",
>>> dst="3555:5555:6666:6666:7777:7777:8888:8888")/TCP(sport=1021,dport=1021)/
>>> ("X"*%s)], iface="%s")' % (mac, padding[1], tx_interface))
>>>           out = self.tester.scapy_execute()
>>>           out = self.dut.send_expect("show port stats all", "testpmd> ",
>>> 120)
>>>           print out
>>>           self.tcpdump_stop_sniff()
>>>           rx_stats = self.number_of_packets(rx_interface)
>>> -        if (rx_stats == 2):
>>> -            self.verify(1, "Pass")
>>> +        self.verify(rx_stats == 2, "FAIL")
>>>
>>>       def test_tso_tunneling(self):
>>>           """
>>>           TSO IPv4 TCP, IPv6 TCP, VXLan testing
>>>           """
>>> +        # RedRockCanyou does not support Tunneling in DPDK yet.
>>> +        if self.nic == "redrockcanyou":
>>> +            print dts.RED("fm10k not support this case\n")
>>> +            return
>>> +
>>>           tx_interface =
>>> self.tester.get_interface(self.tester.get_local_port(self.dut_ports[0]))
>>>           rx_interface =
>>> self.tester.get_interface(self.tester.get_local_port(self.dut_ports[1]))
>>>
>>> @@ -248,7 +253,7 @@ class TestTSO(TestCase):
>>>           self.verify(cores is not None, "Insufficient cores for speed
>>> testing")
>>>           self.coreMask = dts.create_mask(cores)
>>>
>>> -        padding = self.frame_sizes[0] - self.headers_size
>>> +        padding = [self.frame_sizes[0] - self.headers_size,
>>> self.frame_sizes[1] - self.headers_size]
>>>
>>>           self.tester.send_expect("ethtool -K %s rx off tx off tso off gso
>>> off gro off lro off" % tx_interface, "# ")
>>>           self.tester.send_expect("ip l set %s up" % tx_interface, "# ")
>>> @@ -272,6 +277,7 @@ class TestTSO(TestCase):
>>>
>>>           self.dut.send_expect("tso set 800 %d" % self.dut_ports[1],
>>> "testpmd> ", 120)
>>>           self.dut.send_expect("set fwd csum", "testpmd> ", 120)
>>> +        self.dut.send_expect("set promisc all off", "testpmd> ", 120)
>>>           self.dut.send_expect("start", "testpmd> ")
>>>
>>>           self.tester.scapy_foreground()
>>> @@ -279,25 +285,23 @@ class TestTSO(TestCase):
>>>
>>>           # Vxlan test
>>>           self.tcpdump_start_sniffing([tx_interface, rx_interface])
>>> -
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2")/UDP(sport="1021",dport="4789")/VXLA
>>> N()/Ether(dst=%s,src="52:00:00:00:00:00")/IP(src="192.168.1.1",dst="192.16
>>> 8.1.2")/TCP(sport="1021",dport="1021")/("X"*%s)], iface="%s")' % (mac, mac,
>>> padding, tx_interface))
>>> +
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2")/UDP(sport="1021",dport="4789")/VXLA
>>> N()/Ether(dst=%s,src="52:00:00:00:00:00")/IP(src="192.168.1.1",dst="192.16
>>> 8.1.2")/TCP(sport="1021",dport="1021")/("X"*%s)], iface="%s")' % (mac, mac,
>>> padding[0], tx_interface))
Here make me confused, I think that frame_size data structure is used 
for performance test.
For function validation, padding size only related on tso size. I think 
it better to calculate the padding size based on tso size.

>>>           out = self.tester.scapy_execute()
>>>           out = self.dut.send_expect("show port stats all", "testpmd> ",
>>> 120)
>>>           print out
>>>           self.tcpdump_stop_sniff()
>>>           rx_stats = self.number_of_packets(rx_interface)
>>> -        if (rx_stats == 2):
>>> -            self.verify(1, "Pass")
>>> +        self.verify(rx_stats == 1, "FAIL")
Here please add more clearly description of failure issue. DTS will log  
the failure issue and maybe useful for later debug.

>>>
>>>           # Nvgre test
>>>           self.tcpdump_start_sniffing([tx_interface, rx_interface])
>>> -
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2",proto=47)/NVGRE()/Ether(dst=%s,src="
>>> 52:00:00:00:00:00")/IP(src="192.168.1.1",dst="192.168.1.2")/TCP(sport="102
>>> 1",dport="1021")/("X"*%s)], iface="%s")' % (mac, mac, padding,
>>> tx_interface))
>>> +
>>> self.tester.scapy_append('sendp([Ether(dst="%s",src="52:00:00:00:00:00")/I
>>> P(src="192.168.1.1",dst="192.168.1.2",proto=47)/NVGRE()/Ether(dst=%s,src="
>>> 52:00:00:00:00:00")/IP(src="192.168.1.1",dst="192.168.1.2")/TCP(sport="102
>>> 1",dport="1021")/("X"*%s)], iface="%s")' % (mac, mac, padding[1],
>>> tx_interface))
>>>           out = self.tester.scapy_execute()
>>>           out = self.dut.send_expect("show port stats all", "testpmd> ",
>>> 120)
>>>           print out
>>>           self.tcpdump_stop_sniff()
>>>           rx_stats = self.number_of_packets(rx_interface)
>>> -        if (rx_stats == 2):
>>> -            self.verify(1, "Pass")
>>> +        self.verify(rx_stats == 2, "Pass")
Same as previous one.
>>>       def test_perf_TSO_2ports(self):
>>>           """
>>> @@ -347,6 +351,7 @@ class TestTSO(TestCase):
>>>               self.dut.send_expect("csum parse_tunnel on %d" %
>>> self.dut_ports[1], "testpmd> ", 120)
>>>               self.dut.send_expect("tso set 800 %d" % self.dut_ports[1],
>>> "testpmd> ", 120)
>>>               self.dut.send_expect("set fwd csum", "testpmd> ", 120)
>>> +            self.dut.send_expect("set promisc all off", "testpmd> ", 120)
>>>               self.dut.send_expect("start", "testpmd> ")
>>>               for frame_size in self.frame_sizes:
>>>                   wirespeed = self.wirespeed(self.nic, frame_size, 2)
>>> --
>>> 1.9.3
>

      reply	other threads:[~2015-11-04  6:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-14  8:18 Michael Qiu
2015-10-14  8:30 ` Liu, Yong
2015-11-04  6:24   ` Qiu, Michael
2015-11-04  6:53     ` Liu, Yong [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5639AB72.1040509@intel.com \
    --to=yong.liu@intel.com \
    --cc=dts@dpdk.org \
    --cc=michael.qiu@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).