From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8EA0CA2EFC for ; Fri, 20 Sep 2019 18:26:16 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7C56A1F507; Fri, 20 Sep 2019 18:26:16 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id 5D11F1F49B for ; Fri, 20 Sep 2019 18:26:15 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x8KGLwcj009579; Fri, 20 Sep 2019 09:26:14 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-transfer-encoding : mime-version; s=pfpt0818; bh=4RmioO87AGROiwYHo8mjkWm+AeKF+P2l7d4Zl4160/k=; b=iCsU7ZZ/AdNPQafgZJJ2F8q6rXrcVfMDa2WW+ddMFEEmkJ+DwTbm+GXIM2bTacLaT0vp JUtAbvZGnGVPqnlNp78IpofnQojw7PFOufi1kCRWXcYJm+Bhyhf89WHxsim+dTvBfFc2 dKUiEFu8+8fEg2rXveAk7nC3M9loqEk8rC6oaC1WJmkTm/tbWczzg3X0h+vyrW6I9owx /7ep1YuoH3Be1OHNAmGAx1HVJwi9cEEDk8QUDVB2oLIHkNr0Vs6/VTpEUshknHXyB/cT mOZ3yARyCvn7t6NiksLmZe4WP8tIVt42G00BEr7DckP5Le7StgTdQ1jOskfHPMVyIaV0 hQ== Received: from sc-exch02.marvell.com ([199.233.58.182]) by mx0a-0016f401.pphosted.com with ESMTP id 2v3vce15xr-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 20 Sep 2019 09:26:14 -0700 Received: from SC-EXCH01.marvell.com (10.93.176.81) by SC-EXCH02.marvell.com (10.93.176.82) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Fri, 20 Sep 2019 09:26:13 -0700 Received: from NAM05-BY2-obe.outbound.protection.outlook.com (104.47.50.59) by SC-EXCH01.marvell.com (10.93.176.81) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Fri, 20 Sep 2019 09:26:12 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UXCzLZeCfUQYPAYobf+uuyaeq+pA0/o3cfF06sIOfMkJUGPP2GIkhe/y4b2ktivCr2YJYovcCeQJwpUj+Cez0o1qel6s5jwv9BviRkee06mGP7NW93INyNJtLJkBK5wc+li8MZoy+rbzIIdW8ibex7+mZGNjteYkXOYpm47/cArSkhypLbpuNFDZMoY8rWkruA6G3SBOUgnvddo4ldmcY2WXI+YWqVO5Wl9dsLCqOW2ji7tyaQD3PsgICTW23LwVuemmIVFDvLnXiC2g/4SIr9lFBPyTpQgAg50koAfS/m6vw8p2DLRWMzQUwM39OxJYENvJ0SO3lMBZporIUSEb4Q== 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-SenderADCheck; bh=4RmioO87AGROiwYHo8mjkWm+AeKF+P2l7d4Zl4160/k=; b=bHimjn37T+TFYYRSoyIjO7DuctLMHiaUz2FIUSsh4MVBv5N+wlNRDsvDGPFCLCzvrnRxMuJXIpSFSZJt0Bw943xu92LP/JTmY8Q2v0otF5YNYBUHIOQ4sMUAOwfhWoCUqoTYOS8zutVCmWU+DmHNemwf3yh6TXJPWiOB7EHhvbHJEO4rbJej7L65YhOajFWWTNUHVSFf0fC0ayO52X8DzzZvGN2PpjNMqyJ0JcQ8mXeXlTExFvcUVWy4bqoEps5/wQft7lnpFZiqVYeyhWgkhZ0hf7V0+P3/5yRnaBKEn6jscAS6vEQUb3ZKKjypq1HukzXIFkLggaboML5YeqvpZQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector2-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4RmioO87AGROiwYHo8mjkWm+AeKF+P2l7d4Zl4160/k=; b=Sb1yaml6YtsPr5CMUzbZE6V1lOBMZykEq6oHy0NV/zNHmLs2FpiW4CF/MNb0dbOGefdqiSb9n6jyFulULCMosr5VSwGCKNsNS3zbV04WZtQrY9U5xfzD7SoSpNk5QhQtzHSRIEXxIkJzNR+fMhJX8HTN2BgoDSAhWYCZPvxt1M4= Received: from MN2PR18MB2704.namprd18.prod.outlook.com (20.178.255.93) by MN2PR18MB3168.namprd18.prod.outlook.com (10.255.236.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2284.19; Fri, 20 Sep 2019 16:26:11 +0000 Received: from MN2PR18MB2704.namprd18.prod.outlook.com ([fe80::456d:3044:7453:b3c3]) by MN2PR18MB2704.namprd18.prod.outlook.com ([fe80::456d:3044:7453:b3c3%4]) with mapi id 15.20.2284.023; Fri, 20 Sep 2019 16:26:11 +0000 From: Phanendra Vukkisala To: "Li, WenjieX A" CC: Vijaya Bhaskar Annayyolla , Faisal Masood , "dts@dpdk.org" Thread-Topic: [dts] [PATCH] ptype_mapping: Add support to run 'get test' on cavium devices Thread-Index: AQHVb33+oNLsWCTeX0mlp1ub2p1Gyqc0wCcg Date: Fri, 20 Sep 2019 16:26:10 +0000 Message-ID: References: <1568035421-32446-1-git-send-email-pvukkisala@marvell.com> <8688172CD5C0B74590FAE19D9579F94B5379D528@SHSMSX103.ccr.corp.intel.com> In-Reply-To: <8688172CD5C0B74590FAE19D9579F94B5379D528@SHSMSX103.ccr.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [103.43.203.195] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: f156bc9e-fe6e-4673-895e-08d73de73f9d x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600167)(711020)(4605104)(1401327)(2017052603328)(7193020); SRVR:MN2PR18MB3168; x-ms-traffictypediagnostic: MN2PR18MB3168: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2; x-forefront-prvs: 0166B75B74 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(376002)(366004)(39860400002)(346002)(396003)(136003)(13464003)(199004)(189003)(66556008)(66066001)(66476007)(74316002)(66446008)(5660300002)(8936002)(486006)(446003)(11346002)(52536014)(476003)(64756008)(81166006)(7736002)(4326008)(305945005)(71190400001)(6916009)(33656002)(71200400001)(229853002)(186003)(66946007)(5024004)(6436002)(14444005)(6116002)(3846002)(14454004)(9686003)(86362001)(81156014)(53546011)(256004)(76116006)(76176011)(26005)(54906003)(7696005)(55016002)(99286004)(316002)(478600001)(6506007)(102836004)(25786009)(6246003)(2906002); DIR:OUT; SFP:1101; SCL:1; SRVR:MN2PR18MB3168; H:MN2PR18MB2704.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: U/ahWO24gJEoRD3WhBn/Edf80yh1f6MFLXiegzNB58BB/yQfXKRqvu7o3qJdDcPMXNpOLQlWwR8doXe39kUzvmmzRSS6gNCOxqi4CkNW6JPSCwMp6qM+KyrM0n3k2SPdHbT4nwji0SC6IT8ToVqh4wa2pXcMeBXJuMJjISgdyk937PIwTkMT26tATghdCUL/+xHcNk8QwEsJ1F+O6O/LfVe+Gere8/T0ypP09F+QmpekcR7LMZDwVNvN830tVn1HoeSy9oahvP7CiXyLYsomlo3kT37GxBspQvkHKFHzOsJ5HqOZ+AnYGXVSSlntm2N0OttEKCEowAzIiOG5wkshcltOuIvLrWBN3XHVtceVZSs+pq8zF6ZyVYne8LCD8Gy8pvJnYs2r+udKwaIdTcf/udimqj+rtNL1pCNZbFHXj4c= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: f156bc9e-fe6e-4673-895e-08d73de73f9d X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Sep 2019 16:26:10.8943 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 9eIVrku6TnLTEt4snDEZVnm6mOLTg0NLz8u1TgeO9EYn3TOFinwNn7Do9La3CS8rmjIquOL87BQOMVEWaPcI2Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR18MB3168 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.70,1.0.8 definitions=2019-09-20_06:2019-09-20,2019-09-20 signatures=0 Subject: Re: [dts] [PATCH] ptype_mapping: Add support to run 'get test' on cavium devices 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: , Errors-To: dts-bounces@dpdk.org Sender: "dts" Hi Wenjie, Thanks for validation of my patch. Submitted patch to fix this failure.=20 Regards, Phanendra -----Original Message----- From: Li, WenjieX A =20 Sent: Friday, September 20, 2019 11:53 AM To: Phanendra Vukkisala Cc: Vijaya Bhaskar Annayyolla ; Faisal Masood ; dts@dpdk.org Subject: [EXT] RE: [dts] [PATCH] ptype_mapping: Add support to run 'get tes= t' on cavium devices External Email ---------------------------------------------------------------------- Hi Phanendra, With your patch, ptype_mapping failed with ALL i40e NICs: "Failed to detect= INNER_L4_NONFRAG".=20 Attach a log for you. Could you please help to debug it?=20 Thank you! BR, Wenjie > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of=20 > pvukkisala@marvell.com > Sent: Monday, September 9, 2019 9:24 PM > To: dts@dpdk.org > Cc: avijay@marvell.com; fmasood@marvell.com; Phanendra Vukkisala=20 > > Subject: [dts] [PATCH] ptype_mapping: Add support to run 'get test' on=20 > cavium devices >=20 > From: Phanendra Vukkisala >=20 > Modified commands and output according implementation for cavium=20 > platform for cavium devices >=20 > Signed-off-by: Phanendra Vukkisala > --- > tests/TestSuite_ptype_mapping.py | 122=20 > +++++++++++++++++++++++++--------- > ---- > 1 file changed, 82 insertions(+), 40 deletions(-) >=20 > diff --git a/tests/TestSuite_ptype_mapping.py > b/tests/TestSuite_ptype_mapping.py > index d7af657..8b8306c 100644 > --- a/tests/TestSuite_ptype_mapping.py > +++ b/tests/TestSuite_ptype_mapping.py > @@ -45,21 +45,23 @@ class TestPtype_Mapping(TestCase): > Run at the start of each test suite. > """ > self.verify(self.nic in ['fortville_eagle', 'fortville_spirit', > - 'fortville_spirit_single', 'fortville_25g', 'fortpark_TLV', = 'carlsville'], > + 'fortville_spirit_single', 'fortville_25g',=20 > + 'fortpark_TLV', 'carlsville', > 'cavium_a063', 'cavium_a064'], > 'ptype mapping test can not support %s nic' % self.nic) > ports =3D self.dut.get_ports() > - self.verify(len(ports) >=3D 1, "Insufficient ports for testing") > + self.verify(len(ports) >=3D 1, "Insufficient ports for=20 > + testing") > valports =3D [_ for _ in ports if self.tester.get_local_port(_) = !=3D -1] > self.dut_port =3D valports[0] > tester_port =3D self.tester.get_local_port(self.dut_port) > self.tester_iface =3D self.tester.get_interface(tester_port) > - self.dut.send_expect("sed -i -e '" +\ > - "/printf(\" - VLAN tci=3D0x%x\", mb->vlan_tci);" +\ > - "/a\\\\t\\tprintf(\" - pktype: 0x%x\", mb->packet_type);'" += \ > - " app/test-pmd/util.c", "# ", 30, verify =3D True) >=20 > - self.dut.build_install_dpdk(self.dut.target) > - > + if self.nic not in ["cavium_a063", "cavium_a064"]: > + self.dut.send_expect("sed -i -e '" +\ > + "/printf(\" - VLAN tci=3D0x%x\", mb->vlan_tci);" +\ > + "/a\\\\t\\tprintf(\" - pktype: 0x%x\", mb->packet_type);= '" +\ > + " app/test-pmd/util.c", "# ", 30, verify =3D True) > + > + self.dut.build_install_dpdk(self.dut.target) > + >=20 > def set_up(self): > """ > @@ -83,16 +85,17 @@ class TestPtype_Mapping(TestCase): > else: > pkt_names =3D pkt_types[pkt_type] > pkt =3D Packet(pkt_type=3Dpkt_type) > - pkt.send_pkt(tx_port=3Dself.tester_iface) > + pkt.send_pkt(tx_port=3Dself.tester_iface,count=3D4) > out =3D self.dut.get_session_output(timeout=3D2) > - self.verify(sw_ptype in out, > - "Failed to detect correct ptype value") > + if sw_ptype !=3D None: > + self.verify(sw_ptype in out, > + "Failed to detect correct ptype value") > for pkt_layer_name in pkt_names: > if pkt_layer_name not in out: > print utils.RED("Fail to detect %s" % pkt_layer_name= ) > raise VerifyFailure("Failed to detect %s" % pkt_laye= r_name) > print utils.GREEN("Detected %s successfully" % pkt_type) > - > + > def strip_ptype(self, table, hw_ptype): > """ > Strip software packet type from packet mapping table. > @@ -113,35 +116,73 @@ class TestPtype_Mapping(TestCase): > """ > Get ptype mapping table and run ptype test. > """ > - out =3D self.dut_testpmd.execute_cmd('ptype mapping get 0 0') > - time.sleep(3) > - self.verify("255" in out, > - "Failed to get 255 items ptype mapping table!!!") > - out =3D self.dut_testpmd.execute_cmd('ptype mapping get 0 1') > - time.sleep(3) > - self.verify("166" in out, > - "Failed to get 166 items ptype mapping table!!!") > - sw_ptype =3D self.strip_ptype(out, hw_ptype) > - if hw_ptype =3D=3D 38: > + if self.nic in ["cavium_a063", "cavium_a064"]: > + out =3D self.dut_testpmd.execute_cmd('show port 0 ptypes') > + ptype_list =3D ["L2_ETHER", "L3_IPV4", "INNER_L3_IPV6", > "INNER_L4_UDP", "TUNNEL_GRE", "TUNNEL_NVGRE", "TUNNEL_GENEVE",=20 > "TUNNEL_VXLAN"] > + for ptype in ptype_list : > + self.verify( ptype in out, "Failed to get ptype:=20 > + %s"%(ptype)) > pktType =3D { > - "MAC_IP_IPv6_UDP_PKT": > - ["L2_ETHER", "L3_IPV4_EXT_UNKNOWN", > - "TUNNEL_IP", "INNER_L3_IPV6_EXT_UNKNOWN", > + "MAC_IP_IPv6_UDP_PKT": > + ["L2_ETHER", "L3_IPV4", > + "TUNNEL_IP", "INNER_L3_IPV6", > "INNER_L4_UDP"] > } > - elif hw_ptype =3D=3D 75: > + self.run_test(None, pktType, check_ptype) > pktType =3D { > - "MAC_IP_NVGRE_MAC_VLAN_IP_PKT": > - ["L2_ETHER", "L3_IPV4_EXT_UNKNOWN", > - "TUNNEL_GRENAT", "INNER_L2_ETHER_VLAN", > - "INNER_L3_IPV4_EXT_UNKNOWN", "INNER_L4_NONFRAG"] > - } > - self.run_test(sw_ptype, pktType, check_ptype) > - > + "MAC_IP_NVGRE_MAC_VLAN_IP_UDP_PKT": > + ["L2_ETHER", "L3_IPV4", > + "TUNNEL_NVGRE", "INNER_L2_ETHER_VLAN", > + "INNER_L3_IPV4", "INNER_L4_UDP"] > + } > + self.run_test(None, pktType, check_ptype) > + pktType =3D { > + "MAC_IP_UDP_VXLAN_MAC_IP_UDP_PKT": > + ["L2_ETHER", "L3_IPV4", > + "TUNNEL_VXLAN", > + "INNER_L3_IPV4", "INNER_L4_UDP"] > + } > + self.run_test(None, pktType, check_ptype) > + pktType =3D { > + "MAC_IP_UDP_GENEVE_MAC_IP_UDP_PKT": > + ["L2_ETHER", "L3_IPV4", > + "TUNNEL_GENEVE", > + "INNER_L3_IPV4", "INNER_L4_UDP"] > + } > + self.run_test(None, pktType, check_ptype) > + else: > + out =3D self.dut_testpmd.execute_cmd('ptype mapping get 0 0'= ) > + time.sleep(3) > + self.verify("255" in out, > + "Failed to get 255 items ptype mapping table!!!") > + out =3D self.dut_testpmd.execute_cmd('ptype mapping get 0 1'= ) > + time.sleep(3) > + self.verify("166" in out, > + "Failed to get 166 items ptype mapping table!!!") > + sw_ptype =3D self.strip_ptype(out, hw_ptype) > + sw_ptype =3D None > + if hw_ptype =3D=3D 38: > + pktType =3D { > + "MAC_IP_IPv6_UDP_PKT": > + ["L2_ETHER", "L3_IPV4_EXT_UNKNOWN", > + "TUNNEL_IP", "INNER_L3_IPV6_EXT_UNKNOWN", > + "INNER_L4_UDP"] > + } > + elif hw_ptype =3D=3D 75: > + pktType =3D { > + "MAC_IP_NVGRE_MAC_VLAN_IP_UDP_PKT": > + ["L2_ETHER", "L3_IPV4_EXT_UNKNOWN", > + "TUNNEL_GRENAT", "INNER_L2_ETHER_VLAN", > + "INNER_L3_IPV4_EXT_UNKNOWN", "INNER_L4_NONFRAG"= ] > + } > + self.run_test(sw_ptype, pktType, check_ptype) > + > def ptype_mapping_test(self, check_ptype =3D None): > - > - self.run_ptype_test(hw_ptype =3D 38, check_ptype =3D check_ptype= ) > - self.run_ptype_test(hw_ptype =3D 75, check_ptype =3D check_ptype= ) > + > + if self.nic in ["cavium_a063", "cavium_a064"]: > + self.run_ptype_test(hw_ptype =3D None, check_ptype =3D check= _ptype) > + else: > + self.run_ptype_test(hw_ptype =3D 38, check_ptype =3D check_p= type) > + self.run_ptype_test(hw_ptype =3D 75, check_ptype =3D=20 > + check_ptype) >=20 >=20 > def test_ptype_mapping_get(self): > @@ -149,7 +190,7 @@ class TestPtype_Mapping(TestCase): > Get hardware defined ptype to software defined ptype mapping ite= ms. > """ > self.ptype_mapping_test() > - > + > def test_ptype_mapping_reset(self): > """ > Reset packet mapping table after changing table. > @@ -230,7 +271,8 @@ class TestPtype_Mapping(TestCase): > """ > Run after each test suite. > """ > - self.dut.send_expect("sed -i '/printf(\" - pktype: 0x%x\", " +\ > - "mb->packet_type);/d' app/test-pmd/util.c", "# ", 30, verify= =3D True) > - self.dut.build_install_dpdk(self.dut.target) > + if self.nic not in ["cavium_a063", "cavium_a064"]: > + self.dut.send_expect("sed -i '/printf(\" - pktype: 0x%x\", "= +\ > + "mb->packet_type);/d' app/test-pmd/util.c", "# ", 30, ve= rify =3D True) > + self.dut.build_install_dpdk(self.dut.target) > self.dut.kill_all() > -- > 1.7.9.5