[V1,2/2] tests/kernelpf_iavf: remove 2 duplicated vf jumboframe cases
Checks
Commit Message
From: Yu Jiang <yux.jiang@intel.com>
VF with/without jumboframe are duplicated to vf_jumboframe suite,
so remove the two cases
Signed-off-by: Yu Jiang <yux.jiang@intel.com>
---
tests/TestSuite_kernelpf_iavf.py | 72 --------------------------------
1 file changed, 72 deletions(-)
Comments
On Wed, 8 Jun 2022 15:09:55 +0800, "Yu.Jiang" <yux.jiang@intel.com> wrote:
> From: Yu Jiang <yux.jiang@intel.com>
>
> VF with/without jumboframe are duplicated to vf_jumboframe suite,
> so remove the two cases
>
> Signed-off-by: Yu Jiang <yux.jiang@intel.com>
Series applied, thanks
@@ -568,78 +568,6 @@ class TestKernelpfIavf(TestCase):
else:
self.verify(len(receive_pkt) == 1, "Failed to received vlan packet!!!")
- def test_vf_without_jumboframe(self):
- self.tester.send_expect(
- "ifconfig %s mtu %s" % (self.tester_intf, ETHER_JUMBO_FRAME_MTU), "#"
- )
-
- self.vm_testpmd.start_testpmd("all")
- self.vm_testpmd.execute_cmd("set fwd mac")
- self.vm_testpmd.execute_cmd("start")
- self.jumboframes_send_packet(ETHER_STANDARD_MTU - 1, True)
- self.jumboframes_send_packet(ETHER_STANDARD_MTU + 1 + 4 + 4, False)
- self.tester.send_expect(
- "ifconfig %s mtu %s" % (self.tester_intf, ETHER_STANDARD_MTU), "#"
- )
-
- def test_vf_with_jumboframe(self):
- self.tester.send_expect(
- "ifconfig %s mtu %d" % (self.tester_intf, ETHER_JUMBO_FRAME_MTU), "#"
- )
- conf_pkt_len = 3000
- self.vm_testpmd.start_testpmd(
- "all",
- "--max-pkt-len=%d --port-topology=loop --tx-offloads=0x8000" % conf_pkt_len,
- )
- self.vm_testpmd.execute_cmd("set fwd mac")
- self.vm_testpmd.execute_cmd("start")
- self.jumboframes_send_packet(conf_pkt_len - 1, True)
- self.jumboframes_send_packet(conf_pkt_len + 1, False)
- self.tester.send_expect(
- "ifconfig %s mtu %d" % (self.tester_intf, ETHER_STANDARD_MTU), "#"
- )
-
- def jumboframes_send_packet(self, pktsize, received=True):
- """
- Send 1 packet to portid
- """
- tx_pkts_ori, _, tx_bytes_ori = [
- int(_) for _ in self.jumboframes_get_stat(self.vm_port, "tx")
- ]
- rx_pkts_ori, rx_err_ori, rx_bytes_ori = [
- int(_) for _ in self.jumboframes_get_stat(self.vm_port, "rx")
- ]
-
- pkt = Packet(pkt_type="UDP", pkt_len=pktsize)
- pkt.config_layer("ether", {"dst": self.vf_mac, "src": self.tester_mac})
- self.vm_testpmd.execute_cmd("clear port stats all")
- pkt.send_pkt(self.tester, tx_port=self.tester_intf)
-
- time.sleep(1)
-
- tx_pkts, _, tx_bytes = [
- int(_) for _ in self.jumboframes_get_stat(self.port, "tx")
- ]
- rx_pkts, rx_err, rx_bytes = [
- int(_) for _ in self.jumboframes_get_stat(self.vm_port, "rx")
- ]
-
- tx_pkts -= tx_pkts_ori
- tx_bytes -= tx_bytes_ori
- rx_pkts -= rx_pkts_ori
- rx_bytes -= rx_bytes_ori
- rx_err -= rx_err_ori
- if received:
- self.verify(
- (rx_pkts == 1) and (tx_pkts == 1), "Packet forward assert error"
- )
-
- self.verify(rx_bytes + 4 == pktsize, "Rx packet size should be packet size")
-
- self.verify(tx_bytes + 4 == pktsize, "Tx packet size should be packet size")
- else:
- self.verify(rx_err == 1 or tx_pkts == -1, "Packet drop assert error")
-
def test_vf_rss(self):
rss_type = ["ip", "tcp", "udp"]
self.vm_testpmd.start_testpmd("all", "--txq=4 --rxq=4")