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 C7865A0512; Wed, 15 Jan 2020 10:06:59 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BD1331BFFC; Wed, 15 Jan 2020 10:06:59 +0100 (CET) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 7FB521BFFC for ; Wed, 15 Jan 2020 10:06:57 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 Jan 2020 01:06:57 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,322,1574150400"; d="scan'208";a="242810280" Received: from unknown (HELO dpdk-wenjielx-dtspatch135.sh.intel.com) ([10.240.176.135]) by orsmga002.jf.intel.com with ESMTP; 15 Jan 2020 01:06:56 -0800 From: Haiyang Zhao To: dts@dpdk.org Cc: zhaoyan.chen@intel.com, Haiyang Zhao Date: Wed, 15 Jan 2020 17:12:25 +0800 Message-Id: <1579079547-52758-3-git-send-email-haiyangx.zhao@intel.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1579079547-52758-1-git-send-email-haiyangx.zhao@intel.com> References: <1579079547-52758-1-git-send-email-haiyangx.zhao@intel.com> Subject: [dts] [PATCH V1 3/5] framework/dut:add -d parameters in create_eal_parameters when use shared mode 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" *.add -d parameters in create_eal_parameters. *.fix pep8 issues. *.when out returned by self.tester.send_ping is None, the judgement statement will cause an exception, fixed it. Signed-off-by: Haiyang Zhao --- framework/dut.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/framework/dut.py b/framework/dut.py index 5409b93..60745e6 100644 --- a/framework/dut.py +++ b/framework/dut.py @@ -190,7 +190,7 @@ class Dut(Crb): + blank + b_ports_str \ + blank + no_pci \ + blank + vdev - self.prefix_list = [] + self.prefix_list = [] else: eal_str = '-l ' + ','.join(map(str, core_list)) \ + blank + '-n %d' % self.get_memory_channels() \ @@ -215,12 +215,16 @@ class Dut(Crb): eal_str = '-l ' + ','.join(map(str, core_list)) \ + blank + '-n %d' % self.get_memory_channels() \ + blank + pci_str - self.prefix_list = [] + self.prefix_list = [] else: eal_str = '-l ' + ','.join(map(str, core_list)) \ + blank + '-n %d' % self.get_memory_channels() \ + blank + pci_str \ + blank + '--file-prefix=' + file_prefix + use_shared_lib = settings.load_global_setting(settings.HOST_SHARED_LIB_SETTING) + shared_lib_path = settings.load_global_setting(settings.HOST_SHARED_LIB_PATH) + if use_shared_lib == 'true' and shared_lib_path and 'Virt' not in str(self): + eal_str = eal_str + ' -d {}'.format(shared_lib_path) return eal_str @@ -1185,7 +1189,7 @@ class Dut(Crb): out = self.tester.send_ping6( remotePort, ipv6, self.get_mac_address(dutPort)) - if ('64 bytes from' in out): + if out and '64 bytes from' in out: self.logger.info("PORT MAP: [dut %d: tester %d]" % (dutPort, remotePort)) self.ports_map[dutPort] = remotePort hits[remotePort] = True -- 1.8.3.1