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 3E1FAA0562; Fri, 19 Mar 2021 07:47:55 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 358BB406B4; Fri, 19 Mar 2021 07:47:55 +0100 (CET) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id D4C924003F for ; Fri, 19 Mar 2021 07:47:52 +0100 (CET) IronPort-SDR: 4mnU11GC01QqxbVpIQtP61woQp3Ac2tghSR9HTjq7Kk9oi0X2iA7ELToWlalCff9zMBK/m0KMr mdPylXWtbSOw== X-IronPort-AV: E=McAfee;i="6000,8403,9927"; a="209859755" X-IronPort-AV: E=Sophos;i="5.81,261,1610438400"; d="scan'208";a="209859755" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Mar 2021 23:47:52 -0700 IronPort-SDR: S0eboeA+ERnKJcWc172c3rfowZZs2BQVSFhQQp4ATGNF+rU5PdhMYnFy2B0PF847RpEbHcZGzn xH5rUW/v18tA== X-IronPort-AV: E=Sophos;i="5.81,261,1610438400"; d="scan'208";a="606504783" Received: from unknown (HELO localhost.localdomain) ([10.240.183.222]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Mar 2021 23:47:50 -0700 From: Ling Wei To: dts@dpdk.org Cc: Ling Wei Date: Fri, 19 Mar 2021 14:46:50 +0800 Message-Id: <20210319064650.4712-1-weix.ling@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dts] [PATCH V1 6/9] tests/vhost_virtio_user_interrupt:modify hard code bind cbdma device to igb_uio by drivername in execution.cfg 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 Sender: "dts" 1.Modify hard code bind cbdma device to igb_uio by drivername in execution.cfg. 2.Adjust code format. Signed-off-by: Ling Wei --- tests/TestSuite_vhost_virtio_user_interrupt.py | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/tests/TestSuite_vhost_virtio_user_interrupt.py b/tests/TestSuite_vhost_virtio_user_interrupt.py index 29693f43..04c86769 100644 --- a/tests/TestSuite_vhost_virtio_user_interrupt.py +++ b/tests/TestSuite_vhost_virtio_user_interrupt.py @@ -62,7 +62,6 @@ class TestVirtioUserInterrupt(TestCase): self.cbdma_dev_infos = [] self.dmas_info = None self.device_str = None - self.prepare_l3fwd_power() self.tx_port = self.tester.get_local_port(self.dut_ports[0]) self.tx_interface = self.tester.get_interface(self.tx_port) @@ -78,7 +77,6 @@ class TestVirtioUserInterrupt(TestCase): self.dut.send_expect("killall -s INT %s" % self.testpmd_name, "#") self.dut.send_expect("killall %s" % self.l3fwdpower_name, "#") self.dut.send_expect("rm -rf vhost-net*", "#") - self.l3fwd = self.dut.new_session(suite="l3fwd") self.vhost = self.dut.new_session(suite="vhost") self.virtio = self.dut.new_session(suite="virito") @@ -145,7 +143,6 @@ class TestVirtioUserInterrupt(TestCase): else: eal_params = self.dut.create_eal_parameters(cores=self.core_list_vhost, prefix='vhost', no_pci=True, vdevs=vdev) cmd_vhost_user = testcmd + eal_params + para - self.vhost.send_expect(cmd_vhost_user, "testpmd>", 30) self.vhost.send_expect("set fwd mac", "testpmd>", 30) self.vhost.send_expect("start", "testpmd>", 30) @@ -186,6 +183,9 @@ class TestVirtioUserInterrupt(TestCase): """ get all cbdma ports """ + # check driver name in execution.cfg + self.verify(self.drivername == 'igb_uio', + "CBDMA test case only use igb_uio driver, need config drivername=igb_uio in execution.cfg") str_info = 'Misc (rawdev) devices using kernel driver' out = self.dut.send_expect('./usertools/dpdk-devbind.py --status-dev misc', '# ', 30) device_info = out.split('\n') @@ -211,9 +211,7 @@ class TestVirtioUserInterrupt(TestCase): dmas_info += dmas self.dmas_info = dmas_info[:-1] self.device_str = ' '.join(self.used_cbdma) - self.dut.setup_modules(self.target, "igb_uio", "None") - self.dut.send_expect('./usertools/dpdk-devbind.py --force --bind=%s %s %s' % - ("igb_uio", self.device_str, self.pci_info), '# ', 60) + self.dut.send_expect('./usertools/dpdk-devbind.py --force --bind=%s %s' % (self.drivername, self.device_str), '# ', 60) def bind_cbdma_device_to_kernel(self): if self.device_str is not None: @@ -309,7 +307,6 @@ class TestVirtioUserInterrupt(TestCase): self.start_vhost_testpmd(pci="--no-pci") self.start_virtio_user(packed=True) self.check_virtio_side_link_status("up") - self.vhost.send_expect("quit", "#", 20) self.check_virtio_side_link_status("down") @@ -321,7 +318,6 @@ class TestVirtioUserInterrupt(TestCase): self.start_vhost_testpmd(pci=self.used_cbdma, dmas=self.dmas_info) self.start_virtio_user() self.check_virtio_side_link_status("up") - self.vhost.send_expect("quit", "#", 20) self.check_virtio_side_link_status("down") self.dut.send_expect("killall %s" % self.l3fwdpower_name, "#") -- 2.25.1