diff options
author | 2017-03-13 11:01:55 +0200 | |
---|---|---|
committer | 2017-03-13 11:01:55 +0200 | |
commit | dbff547f4d9360d3c48c7b269255234cd31271df (patch) | |
tree | 1bbee86b5a4d9d54fa20140f96ea62b7474f8db2 /scripts/automation/regression/stateless_tests | |
parent | c8d1f318e2d322626e401c9599ba75006d2e8e6c (diff) |
i40e fix of workaround of stuck counters + regression test
Change-Id: I251cb8d346461ccfa4eee8abfda113410160a602
Signed-off-by: Yaroslav Brustinov <ybrustin@cisco.com>
Diffstat (limited to 'scripts/automation/regression/stateless_tests')
-rw-r--r-- | scripts/automation/regression/stateless_tests/stl_rx_test.py | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/scripts/automation/regression/stateless_tests/stl_rx_test.py b/scripts/automation/regression/stateless_tests/stl_rx_test.py index 4e15e03b..347c8e8b 100644 --- a/scripts/automation/regression/stateless_tests/stl_rx_test.py +++ b/scripts/automation/regression/stateless_tests/stl_rx_test.py @@ -100,6 +100,7 @@ class STLRX_Test(CStlGeneral_Test): self.cap = cap drv_name = port_info['driver'] + self.drv_name = drv_name if drv_name == 'net_ixgbe': self.ipv6_support = False else: @@ -613,3 +614,29 @@ class STLRX_Test(CStlGeneral_Test): except STLError as e: assert False , '{0}'.format(e) + + + # counters get stuck in i40e when they are getting to limit. + # this test checks our workaround to this issue + def test_x710_counters_wraparound(self): + if self.drv_name != 'net_i40e': + self.skip('Test is only for i40e.') + + percent = min(20, self.speed * 0.8) # 8G at X710 and 20G at XL710 + total_pkts = 300000000 # send 300 million packets to ensure getting to threshold of reset several times + + s1 = STLStream(name = 'wrapping_stream', + packet = self.pkt, + flow_stats = STLFlowStats(pg_id = 5), + mode = STLTXSingleBurst(total_pkts = total_pkts, + percentage = percent)) + + # add both streams to ports + self.c.add_streams([s1], ports = [self.tx_port]) + + print("\ninjecting {0} packets on port {1}\n".format(total_pkts, self.tx_port)) + + exp = {'pg_id': 5, 'total_pkts': total_pkts, 'pkt_len': s1.get_pkt_len()} + + self.__rx_iteration( [exp] ) + |