From patchwork Mon Oct 12 16:30:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yu Jiang X-Patchwork-Id: 80338 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B60F8A04B6; Mon, 12 Oct 2020 10:30:03 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id AC6691D642; Mon, 12 Oct 2020 10:30:02 +0200 (CEST) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by dpdk.org (Postfix) with ESMTP id A3BE11D642 for ; Mon, 12 Oct 2020 10:30:00 +0200 (CEST) IronPort-SDR: eLlQ6vG9IYdy7K3u+S3iApD2mKoAD2/eD4MTRvq4VEqNeIA1jnUScwM3gMepxedKmsj4Pzd1HB 4mKzLFEHq6lg== X-IronPort-AV: E=McAfee;i="6000,8403,9771"; a="250400930" X-IronPort-AV: E=Sophos;i="5.77,366,1596524400"; d="scan'208";a="250400930" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Oct 2020 01:29:59 -0700 IronPort-SDR: U8cuJn7UJWorl1fNJJ8xwlCoCrXvbEyENXhR3gQe+bIpaOhXzNEygulzQvRe+Fa2oWoaVJ5Eo8 noJRAV/OELDQ== X-IronPort-AV: E=Sophos;i="5.77,366,1596524400"; d="scan'208";a="299221574" Received: from unknown (HELO localhost.localdomain) ([10.240.183.77]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Oct 2020 01:29:58 -0700 From: JiangYuX To: dts@dpdk.org Cc: JiangYu Date: Mon, 12 Oct 2020 16:30:52 +0000 Message-Id: <20201012163052.1266901-1-yux.jiang@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Subject: [dts] [PATCH V1] tests/cryptodev_func: adapt drivername 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 adapt drivername dynamically Signed-off-by: JiangYu Tested-by: JiangYuX --- tests/TestSuite_ipsec_gw_cryptodev_func.py | 2 +- tests/TestSuite_l2fwd_cryptodev_func.py | 2 +- tests/TestSuite_virtio_ipsec_cryptodev_func.py | 7 +++---- tests/TestSuite_virtio_perf_cryptodev_func.py | 7 +++---- tests/TestSuite_virtio_unit_cryptodev_func.py | 2 +- 5 files changed, 9 insertions(+), 11 deletions(-) diff --git a/tests/TestSuite_ipsec_gw_cryptodev_func.py b/tests/TestSuite_ipsec_gw_cryptodev_func.py index 538b939..472b65c 100644 --- a/tests/TestSuite_ipsec_gw_cryptodev_func.py +++ b/tests/TestSuite_ipsec_gw_cryptodev_func.py @@ -76,7 +76,7 @@ class TestIPsecGW(TestCase): self.verify("Error"not in out,"Compilation error") self.verify("No such"not in out,"Compilation error") - cc.bind_qat_device(self) + cc.bind_qat_device(self, self.drivername) self._default_ipsec_gw_opts = { "config": '"(0,0,%s),(1,0,%s)"' % tuple(self.core_list[-2:]), diff --git a/tests/TestSuite_l2fwd_cryptodev_func.py b/tests/TestSuite_l2fwd_cryptodev_func.py index 664aa14..8bafb65 100644 --- a/tests/TestSuite_l2fwd_cryptodev_func.py +++ b/tests/TestSuite_l2fwd_cryptodev_func.py @@ -87,7 +87,7 @@ class TestL2fwdCrypto(TestCase): self.verify("Error" not in out, "Compilation error") self.verify("No such" not in out, "Compilation error") - cc.bind_qat_device(self) + cc.bind_qat_device(self, self.drivername) def set_up(self): pass diff --git a/tests/TestSuite_virtio_ipsec_cryptodev_func.py b/tests/TestSuite_virtio_ipsec_cryptodev_func.py index 3957ee5..d30e0d7 100644 --- a/tests/TestSuite_virtio_ipsec_cryptodev_func.py +++ b/tests/TestSuite_virtio_ipsec_cryptodev_func.py @@ -78,7 +78,7 @@ class VirtioCryptodevIpsecTest(TestCase): if not cc.is_build_skip(self): self.dut.skip_setup = False cc.build_dpdk_with_cryptodev(self) - cc.bind_qat_device(self) + cc.bind_qat_device(self, self.drivername) self.dut.build_dpdk_apps("./examples/vhost_crypto") self.bind_vfio_pci() @@ -231,9 +231,8 @@ class VirtioCryptodevIpsecTest(TestCase): if not self.dut.skip_setup: self.build_user_dpdk(vm_dut) - - vm_dut.setup_modules(self.target, "igb_uio", None) - vm_dut.bind_interfaces_linux('igb_uio') + vm_dut.setup_modules(self.target, self.drivername, None) + vm_dut.bind_interfaces_linux(self.drivername) vm.virtio_list = self.set_virtio_pci(vm_dut) self.logger.info("{} virtio list: {}".format(vm_name, vm.virtio_list)) vm.cores = vm_dut.get_core_list("all") diff --git a/tests/TestSuite_virtio_perf_cryptodev_func.py b/tests/TestSuite_virtio_perf_cryptodev_func.py index e46ee2f..fc319dd 100644 --- a/tests/TestSuite_virtio_perf_cryptodev_func.py +++ b/tests/TestSuite_virtio_perf_cryptodev_func.py @@ -86,7 +86,7 @@ class VirtioCryptodevPerfTest(TestCase): self.dut.skip_setup = False cc.build_dpdk_with_cryptodev(self) self.dut.build_dpdk_apps("./examples/vhost_crypto") - cc.bind_qat_device(self) + cc.bind_qat_device(self, self.drivername) self.vf_assign_method = "vfio-pci" self.dut.setup_modules(None, self.vf_assign_method, None) @@ -191,9 +191,8 @@ class VirtioCryptodevPerfTest(TestCase): if not self.dut.skip_setup: self.build_user_dpdk(vm_dut) - - vm_dut.setup_modules(self.target, "igb_uio", None) - vm_dut.bind_interfaces_linux('igb_uio') + vm_dut.setup_modules(self.target, self.drivername, None) + vm_dut.bind_interfaces_linux(self.drivername) vm.virtio_list = self.set_virtio_pci(vm_dut) self.logger.info("{} virtio list: {}".format(vm_name, vm.virtio_list)) vm.cores = vm_dut.get_core_list("all") diff --git a/tests/TestSuite_virtio_unit_cryptodev_func.py b/tests/TestSuite_virtio_unit_cryptodev_func.py index 336af7a..ee42b5d 100644 --- a/tests/TestSuite_virtio_unit_cryptodev_func.py +++ b/tests/TestSuite_virtio_unit_cryptodev_func.py @@ -57,7 +57,7 @@ class VirtioCryptodevUnitTest(TestCase): if not cc.is_build_skip(self): self.dut.skip_setup = False cc.build_dpdk_with_cryptodev(self) - cc.bind_qat_device(self) + cc.bind_qat_device(self, self.drivername) self.dut.build_dpdk_apps("./examples/vhost_crypto") self.vf_assign_method = "vfio-pci"