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 B9A92A0A02; Mon, 17 May 2021 15:49:32 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9E69740F35; Mon, 17 May 2021 15:49:32 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mails.dpdk.org (Postfix) with ESMTP id 1B8A14014E for ; Mon, 17 May 2021 15:49:30 +0200 (CEST) IronPort-SDR: JKtGHkOmPx+3OSDmQXWIgTIiTXztOILtplDfch+M4lkhCUEbdc71C9cGuTrKKVU5NPdm0i1lx6 tBmW5i3T0giw== X-IronPort-AV: E=McAfee;i="6200,9189,9986"; a="200157669" X-IronPort-AV: E=Sophos;i="5.82,307,1613462400"; d="scan'208";a="200157669" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 May 2021 06:49:22 -0700 IronPort-SDR: iKkaOSHs7hVmDqjETaV2jHKvhtaGXJDC8D3k4IapxJzqn9eM77/k7B31TTpgjOGOhpAQtwfIcK zzKm6bym7zxQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.82,307,1613462400"; d="scan'208";a="437987391" Received: from dpdk-lijuan.sh.intel.com ([10.67.119.192]) by fmsmga008.fm.intel.com with ESMTP; 17 May 2021 06:49:21 -0700 From: Lijuan Tu To: dts@dpdk.org Cc: Lijuan Tu Date: Tue, 18 May 2021 05:46:56 +0800 Message-Id: <1621288016-63122-1-git-send-email-lijuan.tu@intel.com> X-Mailer: git-send-email 1.8.3.1 Subject: [dts] [PATCH] pktgen_ixia: fix a issue taking ownership failed 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" DTS has to take ownership of an ixia port, then can operate it. If the port is owned by other user, DTS has to take ownership forcedly. It seems DTS intend to do above but with wrong code implement. Signed-off-by: Lijuan Tu --- framework/pktgen_ixia.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/framework/pktgen_ixia.py b/framework/pktgen_ixia.py index 80c5cb5..0273f3a 100644 --- a/framework/pktgen_ixia.py +++ b/framework/pktgen_ixia.py @@ -610,13 +610,13 @@ class Ixia(SSHConnection): for item in self.ports]), "% ", 10) if out.strip()[-1] != '0': - return False - out = self.send_expect("ixTakeOwnership [list %s] force" % ' '.join( + self.logger.info("Force to take ownership:") + out = self.send_expect("ixTakeOwnership [list %s] force" % ' '.join( ['[list %d %d %d]' % (self.chasId, item['card'], item['port']) for item in self.ports]), "% ", 10) - if out.strip()[-1] != '0': - return False + if out.strip()[-1] != '0': + return False return True -- 1.8.3.1