From patchwork Thu Sep 9 18:20:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lewei Yang X-Patchwork-Id: 98416 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id CD369A0547; Thu, 9 Sep 2021 11:49:38 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C0E5840041; Thu, 9 Sep 2021 11:49:38 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id 2F4B94003E for ; Thu, 9 Sep 2021 11:49:36 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10101"; a="207970901" X-IronPort-AV: E=Sophos;i="5.85,279,1624345200"; d="scan'208";a="207970901" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Sep 2021 02:49:36 -0700 X-IronPort-AV: E=Sophos;i="5.85,279,1624345200"; d="scan'208";a="470008768" Received: from unknown (HELO localhost.localdomain) ([10.240.183.102]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Sep 2021 02:49:34 -0700 From: Yang Lewei To: dts@dpdk.org Cc: Yang Lewei Date: Thu, 9 Sep 2021 18:20:48 +0000 Message-Id: <20210909182048.26935-1-leweix.yang@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dts] [PATCH V1] tests/TestSuite_veb_switch:fix Rx bytes statistics 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" According to dpdk commit e8326d3, fix Rx bytes statistics. Signed-off-by: Yang Lewei --- tests/TestSuite_veb_switch.py | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/tests/TestSuite_veb_switch.py b/tests/TestSuite_veb_switch.py index cdd2b3c4..915296ff 100644 --- a/tests/TestSuite_veb_switch.py +++ b/tests/TestSuite_veb_switch.py @@ -283,18 +283,10 @@ class TestVEBSwitching(TestCase): self.dut.send_expect("stop", "testpmd>", 2) self.session_secondary.send_expect("stop", "testpmd>", 2) - out = self.session_secondary.send_expect("show port info 0", "testpmd>") - vf1_driver = re.findall("Driver\s*name:\s*(\w+)", out)[0] vf0_tx_stats = self.veb_get_pmd_stats("first", 0, "tx") vf1_rx_stats = self.veb_get_pmd_stats("second", 0, "rx") - if self.kdriver == 'ice': - vf1_rx_stats[-1] = vf1_rx_stats[-1] + 4 - if self.kdriver == 'i40e': - if vf1_driver == 'net_iavf': - vf1_rx_stats[-1] = vf1_rx_stats[-1] + 4 - else: - vf1_rx_stats[-1] = vf1_rx_stats[-1] + vf1_rx_stats[-1] = vf1_rx_stats[-1] + 4 self.verify(vf0_tx_stats[0] != 0, "no packet was sent by VF0") self.verify(vf0_tx_stats == vf1_rx_stats, "VF1 failed to receive packets from VF0")