[02/28] tests/TestSuite_hotplug:Modify the hard coded app parameter to call the platform interface

Message ID 20201208100627.9792-3-junx.w.zhou@intel.com (mailing list archive)
State Accepted
Headers
Series Modify the hard coded app parameter to call the platform interface |

Commit Message

Zhou, JunX W Dec. 8, 2020, 10:06 a.m. UTC
  Signed-off-by: Zhou Jun <junx.w.zhou@intel.com>
---
 tests/TestSuite_hotplug.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
  

Patch

diff --git a/tests/TestSuite_hotplug.py b/tests/TestSuite_hotplug.py
index 22df2306..f40c291c 100644
--- a/tests/TestSuite_hotplug.py
+++ b/tests/TestSuite_hotplug.py
@@ -55,6 +55,7 @@  class TestPortHotPlug(TestCase):
         self.dut_ports = self.dut.get_ports(self.nic)
         self.verify(len(self.dut_ports) >= 2, "Insufficient ports")
         cores = self.dut.get_core_list("1S/4C/1T")
+        self.eal_para = self.dut.create_eal_parameters(cores='1S/4C/1T')
         self.coremask = utils.create_mask(cores)
         self.port = len(self.dut_ports) - 1
         if self.drivername == "vfio-pci:noiommu":
@@ -93,7 +94,7 @@  class TestPortHotPlug(TestCase):
         """
         first run testpmd after attach port
         """
-        cmd = "%s -c %s -n %s -- -i" % (self.path, self.coremask, self.dut.get_memory_channels())
+        cmd = "%s %s -- -i" % (self.path, self.eal_para)
         self.dut.send_expect(cmd, "testpmd>", 60)
         session_secondary = self.dut.new_session()
         session_secondary.send_expect(
@@ -137,7 +138,7 @@  class TestPortHotPlug(TestCase):
             "./usertools/dpdk-devbind.py --bind=%s %s" % (self.driver_name, self.dut.ports_info[self.port]['pci']), "#",
             60)
         self.dut.close_session(session_secondary)
-        cmd = "%s -c %s -n %s -- -i" % (self.path, self.coremask, self.dut.get_memory_channels())
+        cmd = "%s %s -- -i" % (self.path, self.eal_para)
         self.dut.send_expect(cmd, "testpmd>", 60)
         self.detach(self.port)
         self.attach(self.port)