From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id C92A42BE9 for ; Mon, 7 Mar 2016 09:57:01 +0100 (CET) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP; 07 Mar 2016 00:57:00 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,550,1449561600"; d="scan'208";a="665070491" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by FMSMGA003.fm.intel.com with ESMTP; 07 Mar 2016 00:56:58 -0800 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id u278uuHw020619; Mon, 7 Mar 2016 16:56:56 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id u278usj1018779; Mon, 7 Mar 2016 16:56:56 +0800 Received: (from qxu10@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id u278uslN018775; Mon, 7 Mar 2016 16:56:54 +0800 From: Qian Xu To: dts@dpdk.org Date: Mon, 7 Mar 2016 16:56:52 +0800 Message-Id: <1457341012-18743-1-git-send-email-qian.q.xu@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dts] [PATCH]fix: set 100g ixia configuration disable 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: , X-List-Received-Date: Mon, 07 Mar 2016 08:57:02 -0000 This patch fix an issue that if the ixia.cfg doesn't set the enable_rsfec. 1. Change the enable_rsfec to force100g for better understanding. 2. Set force100g disable if user didn't set the value in config file. Signed-off-by: Qian Xu diff --git a/conf/ixia.cfg b/conf/ixia.cfg index 8874801..9deba60 100644 --- a/conf/ixia.cfg +++ b/conf/ixia.cfg @@ -3,7 +3,7 @@ # Version : IXIA TCL server version # IP : IXIA server IP address # Ports : [IXIA port list] -# ixia_enable_rsfec: We need to set this to enable if we need IXIA port work in 100G mode. +# ixia_force100g: We need to set this to enable if we need IXIA port work in 100G mode. [IXIA Group] ixia_version=6.62 ixia_ip=xxx.xxx.xxx.xxx @@ -12,4 +12,4 @@ ixia_ports= card=1,port=2; card=1,port=3; card=1,port=4; -ixia_enable_rsfec=disable +ixia_force100g=disable diff --git a/framework/etgen.py b/framework/etgen.py index e272fd6..081155c 100644 --- a/framework/etgen.py +++ b/framework/etgen.py @@ -155,7 +155,11 @@ class IxiaPacketGenerator(SSHConnection): self.ixiaVersion = ixiaPorts[ixiaRef]["Version"] self.ports = ixiaPorts[ixiaRef]["Ports"] - self.enable_rsfec = ixiaPorts[ixiaRef]['enable_rsfec'] + + if ixiaPorts[ixiaRef].has_key('force100g'): + self.enable100g = ixiaPorts[ixiaRef]['force100g'] + else: + self.enable100g = 'disable' self.logger.info(self.ixiaVersion) self.logger.info(self.ports) @@ -414,7 +418,7 @@ class IxiaPacketGenerator(SSHConnection): item['card'], item['port'])) #if the line rate is 100G and we need this port work in 100G mode, #we need to add some configure to make it so. - if int(self.get_line_rate(self.chasId, item).strip()) == 100000 and self.enable_rsfec == 'enable': + if int(self.get_line_rate(self.chasId, item).strip()) == 100000 and self.enable100g == 'enable': self.add_tcl_cmd("port config -ieeeL1Defaults 0") self.add_tcl_cmd("port config -autonegotiate false") self.add_tcl_cmd("port config -enableRsFec true") -- 2.1.0