From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2E3A7A04C0; Tue, 29 Sep 2020 11:25:29 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B601B1D6F9; Tue, 29 Sep 2020 11:25:27 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 351231D6F6 for ; Tue, 29 Sep 2020 11:25:25 +0200 (CEST) IronPort-SDR: zGNW5fLqEWqQUFZS38QWA3rV/UIQ6GMRBlHcWmY0iZHlELJ/kByBpw3ODIE0Sk2LWEEdCXTaNM EMV5MCV1HO/Q== X-IronPort-AV: E=McAfee;i="6000,8403,9758"; a="161378883" X-IronPort-AV: E=Sophos;i="5.77,318,1596524400"; d="scan'208";a="161378883" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Sep 2020 02:25:23 -0700 IronPort-SDR: 5vY+H3yWE1t4mHtR+pzQkAcMxtHwUy3Hs6EOLbwdjTNw8XtAfejBlRa5CCdgb9S1HjvJ1YCVFa X0EWUdwbqmlQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,318,1596524400"; d="scan'208";a="324611505" Received: from unknown (HELO localhost.localdomain) ([10.240.183.80]) by orsmga002.jf.intel.com with ESMTP; 29 Sep 2020 02:25:22 -0700 From: JiangYuX To: dts@dpdk.org Cc: JiangYu Date: Tue, 29 Sep 2020 17:26:12 +0800 Message-Id: <20200929092613.17645-1-yux.jiang@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dts] [PATCH V1] TestSuite_vhost_event_idx_interrupt/kernelpf_iavf: get the app name to kill X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" From: JiangYu Get app name to kill or call from conf/app_name.cfg file Signed-off-by: JiangYu --- tests/TestSuite_kernelpf_iavf.py | 5 +++-- tests/TestSuite_vhost_event_idx_interrupt.py | 10 +++++----- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/tests/TestSuite_kernelpf_iavf.py b/tests/TestSuite_kernelpf_iavf.py index 66389a2..c47d0b9 100644 --- a/tests/TestSuite_kernelpf_iavf.py +++ b/tests/TestSuite_kernelpf_iavf.py @@ -92,6 +92,7 @@ class TestKernelpfIavf(TestCase): tester_port1 = self.tester.get_local_port(self.dut_ports[1]) self.tester_intf1 = self.tester.get_interface(tester_port1) + self.l3fwdpower_name = self.dut.apps_name['l3fwd-power'].strip().split('/')[-1] def set_up(self): @@ -887,7 +888,7 @@ class TestKernelpfIavf(TestCase): out = self.dut.get_session_output() self.verify('L3FWD_POWER: lcore 6 is waked up from rx interrupt' in out, 'lcore 6 is not waked up') self.verify('L3FWD_POWER: lcore 7 is waked up from rx interrupt' in out, 'lcore 7 is not waked up') - self.dut.send_expect("killall l3fwd-power", "# ", 60, alt_session=True) + self.dut.send_expect("killall %s" % self.l3fwdpower_name, "# ", 60, alt_session=True) def test_vf_unicast(self): self.vm_testpmd.start_testpmd("all") @@ -979,7 +980,7 @@ class TestKernelpfIavf(TestCase): Run after each test case. """ if self.running_case == "test_vf_rx_interrupt": - self.dut.send_expect("killall %s" % self.dut.apps_name['l3fwd-power'].strip().split('/')[-1], "# ", 60, alt_session=True) + self.dut.send_expect("killall %s" % self.l3fwdpower_name, "# ", 60, alt_session=True) self.destroy_2vf_in_2pf() else: self.vm_testpmd.execute_cmd("quit", "#") diff --git a/tests/TestSuite_vhost_event_idx_interrupt.py b/tests/TestSuite_vhost_event_idx_interrupt.py index 9baa626..af3528d 100644 --- a/tests/TestSuite_vhost_event_idx_interrupt.py +++ b/tests/TestSuite_vhost_event_idx_interrupt.py @@ -55,7 +55,7 @@ class TestVhostEventIdxInterrupt(TestCase): self.pci_info = self.dut.ports_info[0]['pci'] self.base_dir = self.dut.base_dir.replace('~', '/root') self.app_l3fwd_power_path = self.dut.apps_name['l3fwd-power'] - self.app_name=self.app_l3fwd_power_path.split('/')[-1] + self.l3fwdpower_name=self.app_l3fwd_power_path.split('/')[-1] self.dut_ports = self.dut.get_ports() self.ports_socket = self.dut.get_numa_id(self.dut_ports[0]) self.cbdma_dev_infos=[] @@ -67,7 +67,7 @@ class TestVhostEventIdxInterrupt(TestCase): """ # Clean the execution ENV self.verify_info = [] - self.dut.send_expect(f"killall {self.app_name}", "#") + self.dut.send_expect(f"killall {self.l3fwdpower_name}", "#") self.dut.send_expect("killall -s INT qemu-system-x86_64", "#") self.dut.send_expect("rm -rf %s/vhost-net*" % self.base_dir, "#") self.vhost = self.dut.new_session(suite="vhost-l3fwd") @@ -158,7 +158,7 @@ class TestVhostEventIdxInterrupt(TestCase): """ relauch l3fwd-power sample for port up """ - self.dut.send_expect("killall -s INT l3fwd-power", "#") + self.dut.send_expect("killall -s INT %s" % self.l3fwdpower_name, "#") # make sure l3fwd-power be killed pid = self.dut.send_expect("ps -ef |grep l3|grep -v grep |awk '{print $2}'", "#") if pid: @@ -285,7 +285,7 @@ class TestVhostEventIdxInterrupt(TestCase): """ for i in range(len(self.vm)): self.vm[i].stop() - self.dut.send_expect("killall l3fwd-power", "#", timeout=2) + self.dut.send_expect("killall %s" % self.l3fwdpower_name, "#", timeout=2) def test_wake_up_split_ring_vhost_user_core_with_event_idx_interrupt(self): """ @@ -442,7 +442,7 @@ class TestVhostEventIdxInterrupt(TestCase): Run after each test case. """ self.dut.close_session(self.vhost) - self.dut.send_expect(f"killall {self.app_name}", "#") + self.dut.send_expect(f"killall {self.l3fwdpower_name}", "#") self.dut.send_expect("killall -s INT qemu-system-x86_64", "#") self.bind_cbdma_device_to_kernel() self.bind_nic_driver(self.dut_ports, self.drivername) -- 2.7.4