diff mbox series

[V4,4/8] tests/ipgre: modify script and test plan to support i40e fimware >= 8.4

Message ID 20221122070927.7634-4-weiyuanx.li@intel.com (mailing list archive)
State Superseded
Headers show
Series [V4,1/8] test_plans/dual_vlan: modify script and test plan to support i40e fimware >= 8.4 | expand

Commit Message

Weiyuan Li Nov. 22, 2022, 7:09 a.m. UTC
Modify script and test plan to i40e support fimware >= 8.4.
When the fimrware >= 8.4, if the filter is to take effect need to enable
extend.

Signed-off-by: Weiyuan Li <weiyuanx.li@intel.com>
---
Tested-by: Song Jiale <songx.jiale@intel.com>

v2:
-use the firmware version to judge whether to add command `extend on`.
v3:
-modify description.
v4:
-modify comments.
-dual_vlan test plan modify table and add header.

 tests/TestSuite_ipgre.py | 13 +++++++++++++
 1 file changed, 13 insertions(+)
diff mbox series

Patch

diff --git a/tests/TestSuite_ipgre.py b/tests/TestSuite_ipgre.py
index cd50c1c4..ecd8e19c 100644
--- a/tests/TestSuite_ipgre.py
+++ b/tests/TestSuite_ipgre.py
@@ -309,9 +309,22 @@  class TestIpgre(TestCase):
                 socket=self.ports_socket,
             )
 
+        # Get the firmware version information
+        try:
+            fwversion, _, _ = self.pmdout.get_firmware_version(
+                self.dut_ports[0]
+            ).split()
+        except ValueError:
+            # nic IXGBE, IGC
+            fwversion = self.pmdout.get_firmware_version(self.dut_ports[0]).split()
+
         self.dut.send_expect("set fwd rxonly", "testpmd>")
         self.dut.send_expect("set verbose 1", "testpmd>")
         self.dut.send_expect("start", "testpmd>")
+        # Because the kernel forces enable Qinq and cannot be closed,
+        # the dpdk can only add 'extend on' to make the VLAN filter work normally.
+        if self.kdriver == "i40e" and fwversion >= "8.40":
+            self.dut.send_expect("vlan set extend off 0", "testpmd>")
 
         # inner ipv4
         config_layers = {