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 66EB4A00C3; Tue, 18 Jan 2022 06:17:47 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3533C426DE; Tue, 18 Jan 2022 06:17:47 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mails.dpdk.org (Postfix) with ESMTP id F421D4067E for ; Tue, 18 Jan 2022 06:17:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1642483065; x=1674019065; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=TC8A87rP0TYCF6K7PyMH8oXiB8Fk0uVNUemdqYDt02I=; b=J47gSQoFsX6CWKpb7w6W145nvec+T0Y1kAZs1musLRoqWMjpAXbNSWKG yiEtmIf73n2chwY3rJAY6xNC9/AI8kqXvpXgtpVn+1QkMQ131qfcbtpvz yH5F583hhYo5mOmMOy8ZqqROEtk5P8jNQaewvKLOMyz5k7udRz46gG7eQ A25NyyYrxVeZZ+NHthzHJGVheLeZxNtxuqHADWTOz7VuEuDVk5R5vNRnm z7uKw/5IUK7q314sWakQbwDH7+sSSFCGyuAPB8TYI07EZrpeLuFvDhnZb +ecQCZuCov5H3VMKrq0jr2KGPWkaHl/d3yScFkue0hrVECohTurej7le9 A==; X-IronPort-AV: E=McAfee;i="6200,9189,10230"; a="242300272" X-IronPort-AV: E=Sophos;i="5.88,296,1635231600"; d="scan'208";a="242300272" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Jan 2022 21:17:43 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,296,1635231600"; d="scan'208";a="531618408" Received: from fmsmsx604.amr.corp.intel.com ([10.18.126.84]) by orsmga008.jf.intel.com with ESMTP; 17 Jan 2022 21:17:43 -0800 Received: from fmsmsx607.amr.corp.intel.com (10.18.126.87) by fmsmsx604.amr.corp.intel.com (10.18.126.84) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Mon, 17 Jan 2022 21:17:43 -0800 Received: from fmsmsx609.amr.corp.intel.com (10.18.126.89) by fmsmsx607.amr.corp.intel.com (10.18.126.87) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Mon, 17 Jan 2022 21:17:42 -0800 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) by fmsmsx609.amr.corp.intel.com (10.18.126.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20 via Frontend Transport; Mon, 17 Jan 2022 21:17:42 -0800 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.173) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Mon, 17 Jan 2022 21:17:42 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ax4x3WE0J0HoONI1FcBeljtcZxxBZmPKXlaXxacNKIxi879f9d+LvqmRTNsoJbzNrC0qz6ZxdqgU6X+ce3KfKA7aCQoxiVi3bWyESK/Tch3otL203+H2NZG4N031SEjRrhY7ng7NvIMUPlfpawnB/Y76wAW+LhBh8/nJQ7sLwoK3R2S4nMSjxjZZ1D6HhPAA3WRuwWAySVp0EnfC5/GmO+5PfGaHdmPZUhegLC7rUhuSu/Wq3YS9oq5ffTCod7Hr5c9EcrwtpbJnYLU1MQl6+zsK9XCFgyPmSS/exBXg631hWZGeepFnWQ+iwvBuoDCA+nE6OQqLaW0X8WSBpmPwQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=unjeIy8KBVXVnlbin6noLgAKZ+9So2mGYcCyzR0KLDc=; b=ZZ3eBxxJUnfB9HXsGkz4HRZH5S4joFhN3dNh+wwLbJxRy6QCsHIu6c3UNG8fzXQ3IqU3h3ecW4JBaGM+T37sJVnYD5SPR81f+Of8UWcAlbEIYqsOwG2lOSOSsOaIo8SfBkx0/xGN4CbOQyP46YVXXVGwxtt3s/vDdE02QPd3+1M0SDiBw5n5mgv4cuCJKfoQcukbzj4cLpdLQWGrACX/sGZ16XK8W/pnnNj0Qw6I4iFpbQnXhFNCmqstMk4ND81E6wc0ToJimhwpSKsxSibeiGHhHhJn0X/MUgXMaa+6b/V3iyEYJaOoqczblNywrvtr8h0/GaXBBqTfTXRKJfjnuA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from SJ0PR11MB5599.namprd11.prod.outlook.com (2603:10b6:a03:3af::21) by BN6PR11MB1331.namprd11.prod.outlook.com (2603:10b6:404:49::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4888.11; Tue, 18 Jan 2022 05:17:39 +0000 Received: from SJ0PR11MB5599.namprd11.prod.outlook.com ([fe80::d977:eec7:9638:3202]) by SJ0PR11MB5599.namprd11.prod.outlook.com ([fe80::d977:eec7:9638:3202%8]) with mapi id 15.20.4888.014; Tue, 18 Jan 2022 05:17:39 +0000 From: "Lin, Xueqin" To: "Tang, Yaqi" , "dts@dpdk.org" CC: "Tang, Yaqi" Subject: RE: [dts][PATCH V3] test_plans/dcf_lifecycle_test_plan: add test plan for CVL DCF enable device reset API Thread-Topic: [dts][PATCH V3] test_plans/dcf_lifecycle_test_plan: add test plan for CVL DCF enable device reset API Thread-Index: AQHYDBbsImn1FWuHSE+by7suDKzG4axoOJ4Q Date: Tue, 18 Jan 2022 05:17:39 +0000 Message-ID: References: <20220118105354.180850-1-yaqi.tang@intel.com> In-Reply-To: <20220118105354.180850-1-yaqi.tang@intel.com> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 3362dfad-742f-411a-7fe9-08d9da41d8e1 x-ms-traffictypediagnostic: BN6PR11MB1331:EE_ x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:525; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 84ieypr5KTNqV5RPEJ+Zh5PPrIFOnn+HcmZwWEqOrSa03hXuiDqT7brxARUACqb84N7nktvBCp8c4Z43iIvwsG5EeaOkOwaFM1rSfyMvFcX0texC3eNS6U49OSMvBSBNP2AalJSYFX0AOj3CJ0FRhxMfnLxhyaWRWXk5lWBy/s4/YPZWLjPF2N9trG3o39i/JTzpDkwUT9cfM2boIkSNtGf7jLsmLESq/D6RPt7FQzsavanS2LuwTA7mSpGYDeffN2rJHWGxrh/OPNfFzJvoE7uOrsPnqYC14irTFdhbx0oduwJNKSmlT5OnzIbqliVD7g6TG5E1xehOcFtJoZGadT77wEYE3LOIROk7gM8+pSD8gQJ7W+O4MmwWuKpa4xyWZJbsxyst3jDEQWNj4AiNNi1pNUPa3mpfNLpZaRUZn5IQ9Fc2E2/NiwlS8jabFEFqVFHqPHp0IVlQN1KoznvKdEtNbTrZi/6+nJzZrpgIR7scPOppR0Y4Rd2ZsQ3t4wwObyoDX4IkrzLHqGPLCWywSAasYtJvNmnC3EXJnzxdRbHYqmHfXQYfRGdsWGIyKJK7jU/Y2vumeOsWsGKpug0zlJcGSpbWF8QbHWbfMX6wlHTfxolbjS80ni/WExy2MFr578Rt/G/KK/54YZHbk228jIjyYfxrEbQj0/ZsL7yasGCFF4S4d+LyPugInD1jEVbp9ar7wIuz3wU3y9QK9o/v3L3Vv1/ewLSJLVY9ywZ1IQ4b8HPPCvZFbEHp1tZqVZozQMRSzMHAy9og6nwUPPIYMbkzOW+LUtzlEvMBB9mN6WWMOBHAAAcefZ3CfkOTQfmzle9SQ53UFG8tbC84bTUNpwd5hQoFaEtXHlkApGRbXdE= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ0PR11MB5599.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(71200400001)(508600001)(966005)(8676002)(7696005)(26005)(53546011)(82960400001)(6506007)(107886003)(122000001)(8936002)(38100700002)(19273905006)(83380400001)(33656002)(52536014)(186003)(4326008)(86362001)(66446008)(66556008)(76116006)(64756008)(66946007)(66476007)(5660300002)(316002)(9686003)(2906002)(30864003)(38070700005)(110136005)(55016003)(579004)(559001)(563064011); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?VXfC6TLgUuEpw+LMDb+SPQhDt9N2Tp1NBDohFot/P6XGGZtdAgO+pGKle0v1?= =?us-ascii?Q?Nx7NK2Hbcwtr1FdJcXeBgJ0zhjcYtJK94pjv2OyNQ354YxQZgPKt7TvLnTOG?= =?us-ascii?Q?V+OqTvQGgfe0+7dPJQooGTJOsZROA0vOBSe+EvloUrMhfOG/MY3evlyaqkQx?= =?us-ascii?Q?6ArBzXCWJmM0c87ysGxm0t27wzMXWQHFCEhZ/f1Go3DvMCUyNtRze99tucdF?= =?us-ascii?Q?DyMJcI90vmp7J3M7W7tQm2dXhGIyQmBdlqZhz8RbDrflWg7fWoNF8ioKatOw?= =?us-ascii?Q?M6aj3eldUC+nDdvMQOCLAlmMzr8zsqAqCm9GWlPV3oj8MUPzGHAtFXCXm0wu?= =?us-ascii?Q?Q04iusOLRWuhQ0UAb4k0omfmFIvLGkHjQAQ0Ha2qsEU64K3l5KLdtDejjqYR?= =?us-ascii?Q?1SU/isMn/c8T3wdBAMihyvJDCD7sTgovP8StDvFbR5nBwHDH4CFWJn8xld7M?= =?us-ascii?Q?DFI4XQ4LwTBRkCJ+ZFvkkfrliq6FUtRI8uHQEnvnYubX7BWs8CDpmWpZ+dyN?= =?us-ascii?Q?WePtaCVnsAZeyHdJVcCqxKs1ZQv4p6ks0aJ1HiOwMYR7+lMfS+GUm7ec0KAZ?= =?us-ascii?Q?/gDGbIjX5M9bNVE+fGxDiBCr9LZoMDWO+5ReRnm4rce/SgRjv63pbPSZnjxn?= =?us-ascii?Q?LAsfUswnjgDcN4744Gv8DOH/XCiH+RYWDiOQMyn/vx6lDdyW7KsnFL/syUI5?= =?us-ascii?Q?iVCcW8N119T/Zoz60juRSyuxhdNnTJUiJ+ym22zVhTaGA8a6JqZLfHcvFIoV?= =?us-ascii?Q?Z9DsuPBMpwT9RD2Se+JIVtYyc3VrG4Qnq3MXxPGgIv9tWSuAuPmT2fFLquG8?= =?us-ascii?Q?eOKV6a+U3ZU/xCYLDX81QXNCBoxHSBvGtHCNzp8XQ5KovLGJ4zwsOv5iHh3+?= =?us-ascii?Q?p/PKCAi/UsqlzLwE2sVyg8Z28jXD7dIOIUebMj4Dz6IeayWFheK7APOvRFdY?= =?us-ascii?Q?Eg1PNc5zapzyjBfGMS1cVV7fCkok9zQ0N6IGA8gTTL/mJCXdU7w+g+zLgUma?= =?us-ascii?Q?gZyH3YCp0y2+yoRwC2N7VpTYb5YwAtrDgGgyIEslNo2M+bHPlbFoRP0rs8Hq?= =?us-ascii?Q?BZAUHxc6tKvh908khB27u0EuGIWuB3LuW0E5nhYXR+LhXTdgWqTxuzfswPSC?= =?us-ascii?Q?oE5aQdFAJ92nJ/2Nzd+egZgi1nkmmAy9Yjd9/Se1OpOEMyYGBdikMhxe8G8u?= =?us-ascii?Q?yZcHEJVyCRr6Q//z0FopCsCKEZHbYRcrB7p/4JX3C1kAsA48HdXPiRV3f4Bb?= =?us-ascii?Q?HL4Te0J2kCF2qXhu4DpJWQq4mug+j2uERNc2i13OUCA34nS4aSsplF7h1eSY?= =?us-ascii?Q?sXShcTLzjEYdEA3XwvqVIjyDxzUFnMa7CNbw6C1fwLV5zdkuDB/VbOeIg/z+?= =?us-ascii?Q?T2myfMqiRK6PB/wBDL7WSryDYr49p9QI/V5MwFgWle7JMYyyAzPsxu14WMy8?= =?us-ascii?Q?D4LMQmRN83pXCmsb2bBaNWqtbXPlEbWuSLqczT9846hzikz9UA9txgyLm9y9?= =?us-ascii?Q?ep456UIuTvM7UT7umkuNBu0TDCCrL5tVU734jRFSYfTuej7RltSZ+txiOiTA?= =?us-ascii?Q?aLlZdIvFAV5t2GVAA39coEI3qp5znIwVe6O+XGmBKz7XYYKYxh0RG0f8iFW5?= =?us-ascii?Q?ug=3D=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SJ0PR11MB5599.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3362dfad-742f-411a-7fe9-08d9da41d8e1 X-MS-Exchange-CrossTenant-originalarrivaltime: 18 Jan 2022 05:17:39.4460 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: gpwetsuLZ9OVeSwul2djb9oTbGXeKM9fFL1O9MpF1RWM8lzV6QD8ZxZfDYbDpw8taqfoWihk8othj2rM08Rf7g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR11MB1331 X-OriginatorOrg: intel.com 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 Thanks, few comments as below.=20 > -----Original Message----- > From: Yaqi Tang > Sent: Tuesday, January 18, 2022 6:54 PM > To: dts@dpdk.org > Cc: Tang, Yaqi > Subject: [dts][PATCH V3] test_plans/dcf_lifecycle_test_plan: add test pla= n for > CVL DCF enable device reset API >=20 > DCF PMD need to support rte_eth_dev_reset.The reason is that when a DCF > instance be killed, all the flow rules still exist in hardware. when DCF = gets to > reconnect, It has already lost the flow context, and if the application w= ants to > create new rules, they may fail because FW reports that the rules already > exist.The current workaround assumes that the user can turn off / turn on= VF > trust mode, so kernel PF will reset DCF by removing all old rules.The > rte_eth_dev_reset API provides a more elegant way for the application to = reset > DCF through the commmad "port reset all" when reconnecting. >=20 > Signed-off-by: Yaqi Tang > Tested-by: Yaqi Tang < yaqi.tang@intel.com> > --- > test_plans/dcf_lifecycle_test_plan.rst | 754 +++++++++++++++++++++++++ > 1 file changed, 754 insertions(+) >=20 > diff --git a/test_plans/dcf_lifecycle_test_plan.rst > b/test_plans/dcf_lifecycle_test_plan.rst > index 4c010e76..a8701338 100644 > --- a/test_plans/dcf_lifecycle_test_plan.rst > +++ b/test_plans/dcf_lifecycle_test_plan.rst > @@ -1071,3 +1071,757 @@ TC34: ACL DCF mode is active, add ACL filters by > way of host based configuration >=20 > # ethtool -N enp24s0f1 flow-type tcp4 src-ip 192.168.10.0 m 0.255.25= 5.255 > dst-port 8000 m 0x00ff action -1 > Added rule with ID 15871 > + > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D > +CVL DCF enable device reset API > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D > + > +Description > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > +The test plan includes ten test cases, such as > +two_testpmd_dcf_reset_port, two_testpmd_dcf_reset_device, > two_testpmd_dcf_reset_port_detach, two_testpmd_dcf_reset_mtu, > two_testpmd_dcf_reset_mac, one_testpmd_dcf_reset_port, > one_testpmd_dcf_reset_device, one_testpmd_dcf_reset_port_detach, > one_testpmd_dcf_reset_mtu, one_testpmd_dcf_reset_mac. > + > +DCF PMD need to support rte_eth_dev_reset.The reason is that when a DCF > +instance be killed, all the flow rules still exist in hardware. when > +DCF gets to reconnect, It has already lost the flow context, and if the > +application wants to create new rules, they may fail because FW reports = that > the rules already exist.The current workaround assumes that the user can = turn > off / turn on VF trust mode, so kernel PF will reset DCF by removing all = old > rules.The rte_eth_dev_reset API provides a more elegant way for the > application to reset DCF through the command "port reset all" when > reconnecting. > + > +Prerequisites > +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > + > +Hardware > +-------- > +Supportted NICs: columbiaville_25g/columbiaville_100g > + > +Software > +-------- > +dpdk: http://dpdk.org/git/dpdk > +scapy: http://www.secdev.org/projects/scapy/ > + > +General Set Up > +-------------- > +1. Copy specific ice package to /lib/firmware/updates/intel/ice/ddp/ice.= pkg, > + then load driver:: > + > + # cp ice_comms-1.3.31.0.pkg /lib/firmware/updates/intel/ice/ddp/ice.= pkg > + # rmmod ice > + # insmod ice.ko > + > +2. Compile DPDK:: > + > + # CC=3Dgcc meson --werror -Denable_kmods=3DTrue -Dlibdir=3Dlib --def= ault- > library=3Dstatic x86_64-native-linuxapp-gcc > + # ninja -C x86_64-native-linuxapp-gcc -j 110 > + > +3. Get the pci device id and interface of DUT and tester:: > + > + # ./usertools/dpdk-devbind.py -s > + > + 0000:3b:00.0 'Ethernet Controller E810-C for SFP 1593' if=3Dens785f0= drv=3Dice > unused=3Dvfio-pci > + 0000:af:00.0 'Ethernet Controller XXV710 for 25GbE SFP28 158b' > + if=3Dens260f0 drv=3Di40e unused=3Dvfio-pci > + Above Prerequisites is common, not special for reset cases, suggest putting= on top of the test plan if need.=20 > +4. Generate 4 VFs on PF0:: > + > + # echo 4 > /sys/bus/pci/devices/0000:3b:00.0/sriov_numvfs > + > +5. Get VF pci device id of DUT. > + > + # ./usertools/dpdk-devbind.py -s > + > + 0000:3b:01.0 'Ethernet Adaptive Virtual Function 1889' if=3Dens785f= 0v0 > drv=3Diavf unused=3Dvfio-pci > + 0000:3b:01.1 'Ethernet Adaptive Virtual Function 1889' > + if=3Dens785f0v1 drv=3Diavf unused=3Dvfio-pci > + > +6. Set VF0 as trust:: > + > + # ip link set ens785f0 vf 0 trust on > + > +7. Bind the VF ports of DUT to dpdk:: > + > + # ./usertools/dpdk-devbind.py -b vfio-pci 3b:01.0 3b:01.1 > + > +Test case > +=3D=3D=3D=3D=3D=3D=3D=3D=3D > + > +Common Steps > +------------ > +The common steps launch two testpmds and kill DCF process, then relaunch > two testpmds. > + > +1. Launch the userland ``testpmd`` application on DUT as follows:: > + > + # ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -v -c 0x6 -n 4 -a > + 0000:3b:01.0,cap=3Ddcf --file-prefix=3Ddcf -- -i Could you follow template format for the whole test plan? > + > +2. Launch another ``testpmd`` application on the VF1 of DUT as follows:: > + > + # ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -v -c 0x18 -n 4 -a > + 0000:3b:01.1 --file-prefix=3Dvf -- -i > + > +3. Set verbose in VF testpmd:: > + > + testpmd> set verbose 1 > + > +4. Set fwd engine and start in VF testpmd:: > + > + testpmd> set fwd mac > + testpmd> start > + > +5. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +6. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +7. Send a matched packet in scapy to VF1, check the VF1 of DUT can recei= ve > the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D'C6:44:32:0A:EC:E1')/IP(src=3D'192.168.0.2', > + dst=3D'192.168.0.3')/("X"*64)],iface=3D"ens260f0",count=3D1) Could you follow template format for the whole test plan, same as below? > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +8. Check the process ID and kill DCF process:: > + > + # ps -ef |grep testpmd > + # kill -9 ##### > + > +9. Relaunch the userland ``testpmd`` application on DUT as follows:: > + > + # ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -v -c 0x6 -n 4 -a > + 0000:3b:01.0,cap=3Ddcf --file-prefix=3Ddcf -- -i > + > +10. Send a matched packet in scapy to VF1, DCF flow rule is still valid = and > check the VF1 of DUT can receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: The VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 1: two_testpmd_dcf_reset_port > +--------------------------------------- > +The test case resets DCF by resetting the port, and DCF should clean up = all old > rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +2. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +3. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +4. Send a matched packet in scapy to VF1, and check the VF1 of DUT can > receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 2: two_testpmd_dcf_reset_device > +----------------------------------------- > +The test case resets DCF by resetting the device, and DCF should clean u= p all > old rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset DCF device:: > + > + # echo 1 > /sys/bus/pci/devices/0000:3b:01.0/reset > + > +2. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check the VF1 of DUT can > receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 3: two_testpmd_dcf_reset_port_detach > +---------------------------------------------- > +The test case resets DCF by detaching the port, and DCF should clean up = all > old rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset DCF device:: > + > + # echo 1 > /sys/bus/pci/devices/0000:3b:01.0/reset > + > +2. Detach and reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop 0 > + testpmd> port detach 0 > + testpmd> port attach 3b:01.0,cap=3Ddcf > + testpmd> port reset 0 > + testpmd> port start 0 > + testpmd> start > + > +3. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check the VF1 of DUT can > receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - le= ngth=3D98 - > nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN L4_NONFRAG - sw > ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x= 0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 4: two_testpmd_dcf_reset_mtu > +-------------------------------------- > +The test case resets DCF by reseting the mtu, and DCF should clean up al= l old > rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Modify the value of mtu:: > + > + # ifconfig ens785f0 mtu 3000 > + > +2. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check the VF1 of DUT can > receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 5: two_testpmd_dcf_reset_mac > +-------------------------------------- > +The test case resets DCF by reseting mac addr, and DCF should clean up a= ll old > rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset VF0 by set mac addr:: > + > + # ip link set ens785f0 vf 0 mac 00:01:02:03:04:05 > + > +2. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1 in DCF testpmd:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 in DCF testpmd and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check the VF1 of DUT can > receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +the VF1 of DUT:: > + > + testpmd> port 0/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Common Steps > +------------ > +The common steps launch one testpmd and kill DCF process, then relaunch > one testpmd. > + > +1. Launch the userland ``testpmd`` application on DUT as follows:: > + > + # ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -v -c 0x6 -n 4 -a > + 3b:01.0,cap=3Ddcf -a 3b:01.1 --file-prefix=3Ddcf -- -i > + > +2. Set verbose:: > + > + testpmd> set verbose 1 > + > +3. Set fwd engine and start:: > + > + testpmd> set fwd mac > + testpmd> start > + > +4. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +5. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +6. Send a matched packet in scapy to VF1, check DUT can receive the pack= et. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +7. Check the process ID and kill DCF process:: > + > + # ps -ef |grep testpmd > + # kill -9 ##### > + > +8. Relaunch the userland ``testpmd`` application on DUT as follows:: > + > + # ./x86_64-native-linuxapp-gcc/app/dpdk-testpmd -v -c 0x6 -n 4 -a > + 3b:01.0,cap=3Ddcf -a 3b:01.1 --file-prefix=3Ddcf -- -i > + > +9. Set verbose:: > + > + testpmd> set verbose 1 > + > +10. Set fwd engine and start:: > + > + testpmd> set fwd mac > + testpmd> start > + > +11. Send a matched packet in scapy to VF1, DCF flow rule is cleared and = check > DUT can't receive the packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> > + > +Test Case 6: one_testpmd_dcf_reset_port > +--------------------------------------- > +The test case resets DCF by resetting the port, and DCF should clean up = all old > rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset port in testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +2. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +3. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +4. Send a matched packet in scapy to VF1, and check DUT can receive the > packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - le= ngth=3D98 - > nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN L4_NONFRAG - sw > ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x= 0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 7: one_testpmd_dcf_reset_device > +----------------------------------------- > +The test case resets DCF by resetting the device, and DCF should clean u= p all > old rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset DCF device:: > + > + # echo 1 > /sys/bus/pci/devices/0000:3b:01.0/reset > + > +2. Reset port in testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check DUT can receive the > packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - > + length=3D98 - nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN > + L4_NONFRAG - sw ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - > + Receive queue=3D0x0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > + RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 8: one_testpmd_dcf_reset_port_detach > +---------------------------------------------- > +The test case resets DCF by detaching the port, and DCF should clean up = all > old rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset DCF device:: > + > + # echo 1 > /sys/bus/pci/devices/0000:3b:01.0/reset > + > +2. Detach and reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop 0 > + testpmd> port detach 0 > + testpmd> port attach 3b:01.0,cap=3Ddcf > + testpmd> port reset 0 > + testpmd> port start 0 > + testpmd> start > + > +3. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check DUT can receive the > packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - le= ngth=3D98 - > nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN L4_NONFRAG - sw > ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x= 0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 9: one_testpmd_dcf_reset_mtu > +-------------------------------------- > +The test case resets DCF by resetting the mtu, and DCF should clean up a= ll old > rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Modify the value of mtu:: > + > + # ifconfig ens785f0 mtu 3000 > + > +2. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check DUT can receive the > packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - le= ngth=3D98 - > nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN L4_NONFRAG - sw > ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x= 0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > + > +Test Case 10: one_testpmd_dcf_reset_mac > +--------------------------------------- > +The test case resets DCF by resetting mac addr, and DCF should clean up = all > old rules. > + > +Test Steps > +~~~~~~~~~~ > +1. Reset VF0 by set mac addr:: > + > + # ip link set ens785f0 vf 0 mac 00:01:02:03:04:05 > + > +2. Reset port in DCF testpmd:: > + > + testpmd> stop > + testpmd> port stop all > + testpmd> port reset all > + testpmd> port start all > + testpmd> start > + > +3. Validate a switch rule to VF1:: > + > + testpmd> flow validate 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule validated > + > +4. Create a switch rule to VF1 and list rules:: > + > + testpmd> flow create 0 priority 0 ingress pattern eth / ipv4 src > + is 192.168.0.2 dst is 192.168.0.3 / end actions vf id 1 / end > + > + Get the message:: > + > + Flow rule #0 created > + > + Check the flow list:: > + > + testpmd> flow list 0 > + > + ID Group Prio Attr Rule > + 0 0 0 i-- ETH IPV4 =3D> VF > + > +5. Send a matched packet in scapy to VF1, and check DUT can receive the > packet. > + > +Tester:: > + > + >>> sendp([Ether(src=3D"00:11:22:33:44:55", > + dst=3D"C6:44:32:0A:EC:E1")/IP(src=3D"192.168.0.2", > + dst=3D"192.168.0.3")/("X"*64)],iface=3D"ens260f0",count=3D1,inter=3D0,v= erbose=3D > + False) > + > +DUT:: > + > + testpmd> port 1/queue 0: received 1 packets > + src=3D00:11:22:33:44:55 - dst=3DC6:44:32:0A:EC:E1 - type=3D0x0800 - le= ngth=3D98 - > nb_segs=3D1 - hw ptype: L2_ETHER L3_IPV4_EXT_UNKNOWN L4_NONFRAG - sw > ptype: L2_ETHER L3_IPV4 - l2_len=3D14 - l3_len=3D20 - Receive queue=3D0x= 0 > + ol_flags: RTE_MBUF_F_RX_L4_CKSUM_GOOD > RTE_MBUF_F_RX_IP_CKSUM_GOOD > RTE_MBUF_F_RX_OUTER_L4_CKSUM_UNKNOWN > -- > 2.25.1