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 011BAA0543; Wed, 14 Dec 2022 08:39:45 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EFCC440684; Wed, 14 Dec 2022 08:39:44 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id 2283E4003F for ; Wed, 14 Dec 2022 08:39:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1671003582; x=1702539582; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=AyHNtLwhYOZo7x4og6yA6eDww4jRd+9bl1iu1v0uphw=; b=XtxkyQ8TsKhupulKS4s5ZphDtdQxWXglQvcoJvwDBFUsI4eD0tBqozvT gMlUKi3lw+w67UciA1olJvTqO5fgyu3ZUseusbgaKEPWnSG1qqORghzji oVyhfHJPVWXnFbWUty6nWUX/rA/I2Ba2lbLhJjtS+6QGotbiNkgsB3I0V st+8xI4uoy6TrWTCR/r/5ydBGJ/2WXMTOu+dPssZhllKOtU1xNSME2rH+ rAv8ozAcvaMuhb4foL5kgR0g8va7XMx7mJtyj3logvxyGxrBvyxsnWRzs CrHvAAX2DOS0uWw7dAfq3Ud0RNcwGd5DhmSTZOh+WhuMfJHMFYAXnVloC A==; X-IronPort-AV: E=McAfee;i="6500,9779,10560"; a="404606483" X-IronPort-AV: E=Sophos;i="5.96,243,1665471600"; d="scan'208";a="404606483" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Dec 2022 23:39:41 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10560"; a="791205010" X-IronPort-AV: E=Sophos;i="5.96,243,1665471600"; d="scan'208";a="791205010" Received: from unknown (HELO localhost.localdomain) ([10.239.252.222]) by fmsmga001-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Dec 2022 23:39:40 -0800 From: Wei Ling To: dts@dpdk.org Cc: Wei Ling Subject: [dts][PATCH V3 2/2] tests/vm2vm_virtio_pmd_cbdma: modify the dmas parameter by DPDK changed Date: Wed, 14 Dec 2022 15:32:09 +0800 Message-Id: <20221214073209.3931352-1-weix.ling@intel.com> X-Mailer: git-send-email 2.25.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 The dmas parameter have been changed by the local patch, so modify the dmas parameter in the testsuite. Signed-off-by: Wei Ling --- tests/TestSuite_vm2vm_virtio_pmd_cbdma.py | 431 +++++++++++----------- 1 file changed, 219 insertions(+), 212 deletions(-) diff --git a/tests/TestSuite_vm2vm_virtio_pmd_cbdma.py b/tests/TestSuite_vm2vm_virtio_pmd_cbdma.py index b00d7b04..7f378937 100644 --- a/tests/TestSuite_vm2vm_virtio_pmd_cbdma.py +++ b/tests/TestSuite_vm2vm_virtio_pmd_cbdma.py @@ -2,15 +2,6 @@ # Copyright(c) 2022 Intel Corporation # -""" -DPDK Test suite. - -Test cases for Vhost-user/Virtio-pmd VM2VM -Test cases for vhost/virtio-pmd(0.95/1.0) VM2VM test with 3 rx/tx paths, -includes mergeable, normal, vector_rx. -Test cases fro vhost/virtio-pmd(1.1) VM2VM test with mergeable path. -About mergeable path check the large packet payload. -""" import re import time @@ -99,6 +90,7 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): self.vhost_user_pmd.start_testpmd( cores=cores, ports=ports, prefix=prefix, eal_param=eal_param, param=param ) + self.vhost_user_pmd.execute_cmd("set fwd mac") self.vhost_user_pmd.execute_cmd("start") def start_vms( @@ -228,66 +220,53 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): """ self.check_path = ["virtio_dev_rx_async", "virtio_dev_tx_async"] self.get_cbdma_ports_info_and_bind_to_dpdk(cbdma_num=16, allow_diff_socket=True) - lcore_dma = ( - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s" + dmas1 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" % ( - self.vhost_core_list[1], self.cbdma_list[0], - self.vhost_core_list[1], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], self.cbdma_list[1], - self.vhost_core_list[1], + ) + ) + dmas2 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" + % ( + self.cbdma_list[2], self.cbdma_list[2], - self.vhost_core_list[1], self.cbdma_list[3], - self.vhost_core_list[2], - self.cbdma_list[4], - self.vhost_core_list[2], - self.cbdma_list[5], - self.vhost_core_list[2], - self.cbdma_list[6], - self.vhost_core_list[2], - self.cbdma_list[7], - self.vhost_core_list[3], - self.cbdma_list[8], - self.vhost_core_list[3], - self.cbdma_list[9], - self.vhost_core_list[3], - self.cbdma_list[10], - self.vhost_core_list[3], - self.cbdma_list[11], - self.vhost_core_list[4], - self.cbdma_list[12], - self.vhost_core_list[4], - self.cbdma_list[13], - self.vhost_core_list[4], - self.cbdma_list[14], - self.vhost_core_list[4], - self.cbdma_list[15], + self.cbdma_list[3], + self.cbdma_list[2], + self.cbdma_list[2], + self.cbdma_list[3], + self.cbdma_list[3], ) ) eal_param = ( - "--vdev 'net_vhost0,iface=vhost-net0,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" - + " --vdev 'net_vhost1,iface=vhost-net1,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" - ) - param = ( - "--nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" - + " --lcore-dma=[%s]" % lcore_dma + "--vdev 'net_vhost0,iface=vhost-net0,queues=8,client=1,dmas=[%s]' " + "--vdev 'net_vhost1,iface=vhost-net1,queues=8,client=1,dmas=[%s]'" + % (dmas1, dmas2) ) + param = " --nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" + self.start_vhost_testpmd( cores=self.vhost_core_list, ports=self.cbdma_list, @@ -313,17 +292,71 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): self.check_packets_of_each_queue(vm_pmd=self.vm0_pmd, queues=8) self.check_packets_of_each_queue(vm_pmd=self.vm1_pmd, queues=8) - for _ in range(5): + for _ in range(3): self.logger.info("Quit and relaunch vhost side testpmd") self.vhost_user_pmd.quit() - eal_param = ( - "--vdev 'net_vhost0,iface=vhost-net0,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;txq4;txq5;rxq2;rxq3;rxq4;rxq5;rxq6;rxq7]'" - + " --vdev 'net_vhost1,iface=vhost-net1,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;txq4;txq5;rxq2;rxq3;rxq4;rxq5;rxq6;rxq7]'" + dmas1 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "txq4@%s;" + "txq5@%s;" + "rxq2@%s;" + "rxq3@%s;" + "rxq4@%s;" + "rxq5@%s;" + "rxq6@%s;" + "rxq7@%s" + % ( + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[2], + self.cbdma_list[3], + self.cbdma_list[4], + self.cbdma_list[1], + self.cbdma_list[2], + self.cbdma_list[3], + self.cbdma_list[4], + self.cbdma_list[5], + self.cbdma_list[6], + self.cbdma_list[7], + ) ) - param = ( - "--nb-cores=4 --txd=1024 --rxd=1024 --rxq=8 --txq=8" - + " --lcore-dma=[%s]" % lcore_dma + dmas2 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "txq4@%s;" + "txq5@%s;" + "rxq2@%s;" + "rxq3@%s;" + "rxq4@%s;" + "rxq5@%s;" + "rxq6@%s;" + "rxq7@%s" + % ( + self.cbdma_list[8], + self.cbdma_list[9], + self.cbdma_list[10], + self.cbdma_list[11], + self.cbdma_list[12], + self.cbdma_list[9], + self.cbdma_list[10], + self.cbdma_list[11], + self.cbdma_list[12], + self.cbdma_list[13], + self.cbdma_list[14], + self.cbdma_list[15], + ) + ) + eal_param = ( + "--vdev 'net_vhost0,iface=vhost-net0,queues=8,client=1,dmas=[%s]' " + "--vdev 'net_vhost1,iface=vhost-net1,queues=8,client=1,dmas=[%s]'" + % (dmas1, dmas2) ) + param = " --nb-cores=4 --txd=1024 --rxd=1024 --rxq=8 --txq=8" self.start_vhost_testpmd( cores=self.vhost_core_list, ports=self.cbdma_list, @@ -344,66 +377,52 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): """ self.check_path = ["virtio_dev_rx_async", "virtio_dev_tx_async"] self.get_cbdma_ports_info_and_bind_to_dpdk(cbdma_num=16, allow_diff_socket=True) - lcore_dma = ( - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s" + dmas1 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" % ( - self.vhost_core_list[1], self.cbdma_list[0], - self.vhost_core_list[1], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], self.cbdma_list[1], - self.vhost_core_list[1], - self.cbdma_list[2], - self.vhost_core_list[1], - self.cbdma_list[3], - self.vhost_core_list[2], - self.cbdma_list[4], - self.vhost_core_list[2], - self.cbdma_list[5], - self.vhost_core_list[2], - self.cbdma_list[6], - self.vhost_core_list[2], - self.cbdma_list[7], - self.vhost_core_list[3], - self.cbdma_list[8], - self.vhost_core_list[3], - self.cbdma_list[9], - self.vhost_core_list[3], - self.cbdma_list[10], - self.vhost_core_list[3], - self.cbdma_list[11], - self.vhost_core_list[4], - self.cbdma_list[12], - self.vhost_core_list[4], - self.cbdma_list[13], - self.vhost_core_list[4], - self.cbdma_list[14], - self.vhost_core_list[4], - self.cbdma_list[15], ) ) - eal_param = ( - "--vdev 'net_vhost0,iface=vhost-net0,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" - + " --vdev 'net_vhost1,iface=vhost-net1,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" + dmas2 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" + % ( + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + ) ) - param = ( - "--nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" - + " --lcore-dma=[%s]" % lcore_dma + eal_param = ( + "--vdev 'net_vhost0,iface=vhost-net0,queues=8,client=1,dmas=[%s]' " + "--vdev 'net_vhost1,iface=vhost-net1,queues=8,client=1,dmas=[%s]'" + % (dmas1, dmas2) ) + param = " --nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" self.start_vhost_testpmd( cores=self.vhost_core_list, ports=self.cbdma_list, @@ -437,66 +456,52 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): """ self.check_path = ["virtio_dev_rx_async", "virtio_dev_tx_async"] self.get_cbdma_ports_info_and_bind_to_dpdk(cbdma_num=16, allow_diff_socket=True) - lcore_dma = ( - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s" + dmas1 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" % ( - self.vhost_core_list[1], self.cbdma_list[0], - self.vhost_core_list[1], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], self.cbdma_list[1], - self.vhost_core_list[1], - self.cbdma_list[2], - self.vhost_core_list[1], - self.cbdma_list[3], - self.vhost_core_list[2], - self.cbdma_list[4], - self.vhost_core_list[2], - self.cbdma_list[5], - self.vhost_core_list[2], - self.cbdma_list[6], - self.vhost_core_list[2], - self.cbdma_list[7], - self.vhost_core_list[3], - self.cbdma_list[8], - self.vhost_core_list[3], - self.cbdma_list[9], - self.vhost_core_list[3], - self.cbdma_list[10], - self.vhost_core_list[3], - self.cbdma_list[11], - self.vhost_core_list[4], - self.cbdma_list[12], - self.vhost_core_list[4], - self.cbdma_list[13], - self.vhost_core_list[4], - self.cbdma_list[14], - self.vhost_core_list[4], - self.cbdma_list[15], ) ) - eal_param = ( - "--vdev 'net_vhost0,iface=vhost-net0,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" - + " --vdev 'net_vhost1,iface=vhost-net1,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;rxq0;rxq1;rxq2;rxq3]'" + dmas2 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "rxq0@%s;" + "rxq1@%s;" + "rxq2@%s;" + "rxq3@%s" + % ( + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + self.cbdma_list[0], + self.cbdma_list[0], + self.cbdma_list[1], + self.cbdma_list[1], + ) ) - param = ( - "--nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" - + " --lcore-dma=[%s]" % lcore_dma + eal_param = ( + "--vdev 'net_vhost0,iface=vhost-net0,queues=8,client=1,dmas=[%s]' " + "--vdev 'net_vhost1,iface=vhost-net1,queues=8,client=1,dmas=[%s]'" + % (dmas1, dmas2) ) + param = " --nb-cores=4 --txd=1024 --rxd=1024 --rxq=4 --txq=4" self.start_vhost_testpmd( cores=self.vhost_core_list, ports=self.cbdma_list, @@ -545,66 +550,68 @@ class TestVM2VMVirtioPmdCBDMA(TestCase): """ self.check_path = ["virtio_dev_rx_async", "virtio_dev_tx_async"] self.get_cbdma_ports_info_and_bind_to_dpdk(cbdma_num=16, allow_diff_socket=True) - lcore_dma = ( - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s," - "lcore%s@%s" + dmas1 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "txq4@%s;" + "txq5@%s;" + "rxq2@%s;" + "rxq3@%s;" + "rxq4@%s;" + "rxq5@%s;" + "rxq6@%s;" + "rxq7@%s" % ( - self.vhost_core_list[1], self.cbdma_list[0], - self.vhost_core_list[1], self.cbdma_list[1], - self.vhost_core_list[1], self.cbdma_list[2], - self.vhost_core_list[1], self.cbdma_list[3], - self.vhost_core_list[2], self.cbdma_list[4], - self.vhost_core_list[2], + self.cbdma_list[1], + self.cbdma_list[2], + self.cbdma_list[3], + self.cbdma_list[4], self.cbdma_list[5], - self.vhost_core_list[2], self.cbdma_list[6], - self.vhost_core_list[2], self.cbdma_list[7], - self.vhost_core_list[3], + ) + ) + dmas2 = ( + "txq0@%s;" + "txq1@%s;" + "txq2@%s;" + "txq3@%s;" + "txq4@%s;" + "txq5@%s;" + "rxq2@%s;" + "rxq3@%s;" + "rxq4@%s;" + "rxq5@%s;" + "rxq6@%s;" + "rxq7@%s" + % ( self.cbdma_list[8], - self.vhost_core_list[3], self.cbdma_list[9], - self.vhost_core_list[3], self.cbdma_list[10], - self.vhost_core_list[3], self.cbdma_list[11], - self.vhost_core_list[4], self.cbdma_list[12], - self.vhost_core_list[4], + self.cbdma_list[9], + self.cbdma_list[10], + self.cbdma_list[11], + self.cbdma_list[12], self.cbdma_list[13], - self.vhost_core_list[4], self.cbdma_list[14], - self.vhost_core_list[4], self.cbdma_list[15], ) ) eal_param = ( - "--vdev 'net_vhost0,iface=vhost-net0,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;txq4;txq5;rxq2;rxq3;rxq4;rxq5;rxq6;rxq7]'" - + " --vdev 'net_vhost1,iface=vhost-net1,client=1,queues=8,dmas=[txq0;txq1;txq2;txq3;txq4;txq5;rxq2;rxq3;rxq4;rxq5;rxq6;rxq7]'" - ) - param = ( - "--nb-cores=4 --txd=1024 --rxd=1024 --rxq=8 --txq=8" - + " --lcore-dma=[%s]" % lcore_dma + "--vdev 'net_vhost0,iface=vhost-net0,queues=8,client=1,dmas=[%s]' " + "--vdev 'net_vhost1,iface=vhost-net1,queues=8,client=1,dmas=[%s]'" + % (dmas1, dmas2) ) + param = " --nb-cores=4 --txd=1024 --rxd=1024 --rxq=8 --txq=8" self.start_vhost_testpmd( cores=self.vhost_core_list, ports=self.cbdma_list, -- 2.25.1