From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 52ADA42BED; Wed, 31 May 2023 08:41:52 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 28ED740ED7; Wed, 31 May 2023 08:41:52 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id C882D40A82 for ; Wed, 31 May 2023 08:41:49 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1685515309; x=1717051309; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=iLxzVRLpRJJ5qIAuuBhNIl5lCgjRteDEJ/AVOPJYb5Y=; b=eBJdu12YGoFH34aIMEdXm9bkWNEEhq+onnXKO+5QDKnEN4bqHidNocrU 7uzPvud4iRHwRWSB34pE5jgIN6eBk7LXfztQkGNkoHgOMimwz5jq5RLIP 2oiqp7KOWgBJMo4nQgffdvzyev5e/XlgG94xCC1wOUyO+j+wFRrRaOU7t oATxui/ap13sVL40dzkr+OqoZXa/4ARadh5s9UukqvHmFrNIJbko3Xj4u x7zq5BXvzMKVh5gu2BfjGwCFYtdbBccTLVRdHFbQcCJg9ziVx31LDXQm5 anaJQDzlSQ95f+rcKWlWIrOLk7plS3GW2UGBVRE/x6s6Pq/7lIg0Vmf+D w==; X-IronPort-AV: E=McAfee;i="6600,9927,10726"; a="441510314" X-IronPort-AV: E=Sophos;i="6.00,205,1681196400"; d="scan'208";a="441510314" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 May 2023 23:41:48 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10726"; a="700984357" X-IronPort-AV: E=Sophos;i="6.00,205,1681196400"; d="scan'208";a="700984357" Received: from unknown (HELO tester97VF6024..) ([10.239.252.97]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 May 2023 23:41:28 -0700 From: Weiyuan Li To: dts@dpdk.org Cc: Weiyuan Li Subject: [dts][PATCH V1] tests/vf_interrupt_pmd: support eal_param -a to avoid running containers conflict Date: Wed, 31 May 2023 14:41:13 +0000 Message-Id: <20230531144113.200587-1-weiyuanx.li@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.29 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 Test suite interrupt case modification script supports eal_param -a to avoid container conflicts. Signed-off-by: Weiyuan Li --- tests/TestSuite_vf_interrupt_pmd.py | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/tests/TestSuite_vf_interrupt_pmd.py b/tests/TestSuite_vf_interrupt_pmd.py index 391b8f9b..249449c5 100644 --- a/tests/TestSuite_vf_interrupt_pmd.py +++ b/tests/TestSuite_vf_interrupt_pmd.py @@ -93,13 +93,14 @@ class TestVfInterruptPmd(TestCase): self.host_intf = self.dut.ports_info[self.used_dut_port]["intf"] self.dut.send_expect("ifconfig %s up" % self.host_intf, "#", 3) - def begin_l3fwd_power(self, use_dut): + def begin_l3fwd_power(self, use_dut, vf_pci_addr): """ begin l3fwd-power """ cmd_vhost_net = ( self.path - + "-n %d -c %s" % (use_dut.get_memory_channels(), self.core_mask_user) + + "-n %d -c %s -a %s" + % (use_dut.get_memory_channels(), self.core_mask_user, vf_pci_addr) + " -- -P -p 1 --config='(0,0,%s)'" % self.core_user ) try: @@ -114,7 +115,7 @@ class TestVfInterruptPmd(TestCase): "ERROR: Failed to launch l3fwd-power sample: %s" % str(e) ) - def begin_l3fwd_power_multi_queues(self, use_dut): + def begin_l3fwd_power_multi_queues(self, use_dut, pci_addr): """ begin l3fwd-power """ @@ -125,7 +126,7 @@ class TestVfInterruptPmd(TestCase): config_info += "(0,%d,%d)" % (queue, queue) cmd_vhost_net = ( self.path - + "-l 0-%d -n 4 -- -P -p 0x1" % queue + + "-l 0-%d -n 4 -a %s -- -P -p 0x1" % (queue, pci_addr) + " --config='%s'" % config_info ) try: @@ -246,13 +247,15 @@ class TestVfInterruptPmd(TestCase): self.used_dut_port_0 = self.dut_ports[0] self.dut.generate_sriov_vfs_by_port(self.used_dut_port_0, 1, driver=driver) self.sriov_vfs_port_0 = self.dut.ports_info[self.used_dut_port_0]["vfs_port"] + vf_pci_list = self.dut.ports_info[self.used_dut_port_0].get("sriov_vfs_pci") + vf_pci_addr = vf_pci_list[0] if vf_pci_list else "" for port in self.sriov_vfs_port_0: port.bind_driver("vfio-pci") # set vf mac self.dut.send_expect( "ip link set %s vf 0 mac %s" % (self.host_intf, self.vf_mac), "# " ) - self.begin_l3fwd_power(self.dut) + self.begin_l3fwd_power(self.dut, vf_pci_addr) self.send_packet(self.vf_mac, self.rx_intf_0, self.dut) self.verify( "lcore %s is waked up from rx interrupt on port 0" % self.core_user @@ -288,13 +291,15 @@ class TestVfInterruptPmd(TestCase): self.used_dut_port_0 = self.dut_ports[0] self.dut.generate_sriov_vfs_by_port(self.used_dut_port_0, 1, driver=driver) self.sriov_vfs_port_0 = self.dut.ports_info[self.used_dut_port_0]["vfs_port"] + vf_pci_list = self.dut.ports_info[self.used_dut_port_0].get("sriov_vfs_pci") + vf_pci_addr = vf_pci_list[0] if vf_pci_list else "" for port in self.sriov_vfs_port_0: port.bind_driver("vfio-pci") # set vf mac self.dut.send_expect( "ip link set %s vf 0 mac %s" % (self.host_intf, self.vf_mac), "# " ) - self.begin_l3fwd_power_multi_queues(self.dut) + self.begin_l3fwd_power_multi_queues(self.dut, vf_pci_addr) stroutput = "" for ip in range(2, 30): self.send_packet_loop(self.vf_mac, self.rx_intf_0, self.dut, ip) -- 2.34.1