@@ -1719,8 +1719,7 @@ class ICEDCFSwitchFilterTest(TestCase):
time.sleep(5)
def reload_ice(self):
- self.dut.send_expect("rmmod ice", "# ", 15)
- self.dut.send_expect("modprobe ice", "# ", 15)
+ self.dut.send_expect("rmmod ice && modprobe ice", "# ", 60)
def set_up(self):
"""
@@ -1748,8 +1747,8 @@ class ICEDCFSwitchFilterTest(TestCase):
launch testpmd with the command
"""
command = self.create_testpmd_command()
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1", "testpmd> ", 15)
self.dut.send_expect("set fwd rxonly", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2265,8 +2264,8 @@ class ICEDCFSwitchFilterTest(TestCase):
port_options={vf0_pci: "cap=dcf"},
)
command = self.path + all_eal_param + " -- -i"
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1,2", "testpmd> ", 15)
self.dut.send_expect("set fwd rxonly", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2322,8 +2321,8 @@ class ICEDCFSwitchFilterTest(TestCase):
port_options={vf0_pci: "cap=dcf"},
)
command = self.path + all_eal_param + " -- -i"
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1,2", "testpmd> ", 15)
self.dut.send_expect("set fwd rxonly", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2370,8 +2369,8 @@ class ICEDCFSwitchFilterTest(TestCase):
self.setup_1pf_vfs_env()
# launch testpmd
command = self.create_testpmd_command()
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1", "testpmd> ", 15)
self.dut.send_expect("set fwd mac", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2406,8 +2405,8 @@ class ICEDCFSwitchFilterTest(TestCase):
port_options={vf0_pci: "cap=dcf"},
)
command = self.path + all_eal_param + " -- -i"
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1,2", "testpmd> ", 15)
self.dut.send_expect("set fwd mac", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2472,8 +2471,8 @@ class ICEDCFSwitchFilterTest(TestCase):
cores="1S/4C/1T", ports=[vf0_pci], port_options={vf0_pci: "cap=dcf"}
)
command = self.path + all_eal_param + " -- -i"
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
# generate max_vf_number-1 rules to each vf and matched packets
for i in range(1, max_vf_number):
rte_flow_pattern = (
@@ -2624,8 +2623,8 @@ class ICEDCFSwitchFilterTest(TestCase):
port_options={vf0_pci: "cap=dcf"},
)
command = self.path + all_eal_param + " -- -i"
- out = self.dut.send_expect(command, "testpmd> ", 15)
self.testpmd_status = "running"
+ out = self.dut.send_expect(command, "testpmd> ", 15)
self.dut.send_expect("set portlist 1,2", "testpmd> ", 15)
self.dut.send_expect("set fwd rxonly", "testpmd> ", 15)
self.dut.send_expect("set verbose 1", "testpmd> ", 15)
@@ -2680,7 +2679,7 @@ class ICEDCFSwitchFilterTest(TestCase):
# destroy vfs
for port_id in self.dut_ports:
self.dut.destroy_sriov_vfs_by_port(port_id)
- self.testpmd_status = "close"
+ self.testpmd_status = "close"
if getattr(self, "session_secondary", None):
self.dut.close_session(self.session_secondary)