From patchwork Mon May 9 07:46:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Weiyuan Li X-Patchwork-Id: 110912 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 30943A0508; Mon, 9 May 2022 09:46:32 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2B3ED41156; Mon, 9 May 2022 09:46:32 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 5878340691 for ; Mon, 9 May 2022 09:46:31 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652082391; x=1683618391; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=hYbfWs1Ro6zpYYboDtMv5Et1HBhQHgGx8HepHHQ+8/k=; b=P2irl9RMVsthqFBMfR6DWFMC4jpvN+mUsrSNe56HO6+qSRaG5umGxHQU 4W09EiJpuVbkGUircJTxpQn765bkc+u7Ib83MNWwA7vzkOLnh9FTE3Cso DjHeCBpOTB4RYVpPmQ2N71xGXDqixrYkRC+uOboCNcdB51IDYcytgFEAq U0xc7WXrS6+s6B4OrUttspqjCsaTPs+RGtj8NrZ97zX3gM/l4HwRLxxxq FUZ9xBNeIrU8KvigpvpdWi36/SaJHAbzq7+LOqxwYIdRgZjOshSWJappz 8sK9oJ/nW/PWQ9dy/EsQkRQ7o9FWRu79Bn6m7r/fEOAuHeLpD7NDyCsGM g==; X-IronPort-AV: E=McAfee;i="6400,9594,10341"; a="249508554" X-IronPort-AV: E=Sophos;i="5.91,210,1647327600"; d="scan'208";a="249508554" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 May 2022 00:46:30 -0700 X-IronPort-AV: E=Sophos;i="5.91,210,1647327600"; d="scan'208";a="519089688" Received: from unknown (HELO dut61..) ([10.239.251.41]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 May 2022 00:46:28 -0700 From: Weiyuan Li To: dts@dpdk.org, yuan.peng@intel.com Cc: Weiyuan Li Subject: [dts][PATCH V1 2/2] tests/vf_smoke modify ixgbe support vf jumbo verify. Date: Mon, 9 May 2022 15:46:39 +0800 Message-Id: <20220509074639.4135273-2-weiyuanx.li@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220509074639.4135273-1-weiyuanx.li@intel.com> References: <20220509074639.4135273-1-weiyuanx.li@intel.com> MIME-Version: 1.0 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 Modify script supports set PF MTU for ixgbe driver. Signed-off-by: Weiyuan Li Tested-by: Lingli Chen --- tests/TestSuite_vf_smoke.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tests/TestSuite_vf_smoke.py b/tests/TestSuite_vf_smoke.py index e4f0c31b..685a54a0 100644 --- a/tests/TestSuite_vf_smoke.py +++ b/tests/TestSuite_vf_smoke.py @@ -32,6 +32,7 @@ from framework.packet import Packet from framework.pmd_output import PmdOutput from framework.test_case import TestCase +from framework.utils import RED from .smoke_base import ( DEFAULT_MTU_VALUE, @@ -74,6 +75,7 @@ class TestVfSmoke(TestCase): # generate vf self.dut.bind_interfaces_linux(self.kdriver) + self.set_pf_mtu() self.dut.generate_sriov_vfs_by_port(self.smoke_dut_ports[0], 1, self.kdriver) self.vf_ports = self.dut.ports_info[self.smoke_dut_ports[0]]["vfs_port"] self.verify(len(self.vf_ports) != 0, "VF create failed") @@ -121,6 +123,12 @@ class TestVfSmoke(TestCase): if out == "" or "No such file or directory" in out: self.vf_launch_dpdk_app() + def set_pf_mtu(self): + self.dut.send_expect(f"ifconfig {self.pf_interface} mtu {JUMBO_FRAME_LENGTH}", "# ") + out = self.dut.send_expect(f"ip link show {self.pf_interface}", "# ") + if '9000' not in out: + print(RED("Please set mtu for case vf_jumbo_frames case!")) + def vf_launch_dpdk_app(self): self.pmd_out.start_testpmd(cores=self.cores, ports=self.ports, param=self.param) @@ -137,7 +145,7 @@ class TestVfSmoke(TestCase): self.dut.send_expect("set fwd mac", "testpmd> ") self.dut.send_expect("start", "testpmd> ") self.pmd_out.wait_link_status_up(self.smoke_dut_ports[0]) - result = self.test_func.check_jumbo_frames() + result = self.test_func.check_jumbo_frames(self.kdriver) self.verify(result, "enable disable jumbo frames failed") def test_vf_rss(self):