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 32762A0588; Tue, 21 Apr 2020 11:45:11 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 01DDA1D8D8; Tue, 21 Apr 2020 11:45:10 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id 784121C1EB for ; Tue, 21 Apr 2020 11:45:07 +0200 (CEST) IronPort-SDR: rLbTQQ4oMWzVrr4HfVUZDp/PnSQnxRSPV4UzKCjVdRSQFab4OhI2cvV4d96gK6H8YsLnX0OJs+ fAqfrFX6scvA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Apr 2020 02:45:06 -0700 IronPort-SDR: S6dZU3DHX/GcWITUOwbry+SzmQ4IXbmNX2VJLMAJp5EEGS4bWwrlwesYhER9m9hLqoDi9FXvhp ktIYqAazLpTg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,409,1580803200"; d="scan'208";a="247131429" Received: from orsmsx104.amr.corp.intel.com ([10.22.225.131]) by fmsmga008.fm.intel.com with ESMTP; 21 Apr 2020 02:45:06 -0700 Received: from orsmsx608.amr.corp.intel.com (10.22.229.21) by ORSMSX104.amr.corp.intel.com (10.22.225.131) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 21 Apr 2020 02:45:05 -0700 Received: from orsmsx608.amr.corp.intel.com (10.22.229.21) by ORSMSX608.amr.corp.intel.com (10.22.229.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Tue, 21 Apr 2020 02:45:05 -0700 Received: from ORSEDG002.ED.cps.intel.com (10.7.248.5) by orsmsx608.amr.corp.intel.com (10.22.229.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.1713.5 via Frontend Transport; Tue, 21 Apr 2020 02:45:05 -0700 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (104.47.56.169) by edgegateway.intel.com (134.134.137.101) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 21 Apr 2020 02:45:02 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RxMM0thFwC7dg/dDCzBFq42eFJIJHygygDPPIxQOdVLiXuwUH3lGD4UxLxhcs+SqlFc9mQWRMqzqK8AdCcr/bquTygSlTWqmZQd5Oq6WbG4zbd+KmGA2iIK/C7UDlRLrM4J5p/UWuiM+8BSLKb2pU4/sLLpg8wgWtLdgqo8yKwgP+LwFtgVCQgsD3eEi+3t9rt3pbSGcHAvj7uzmM7EOw9er0qHJd6us8QOSKkG8DW0RUmkQF8sAkwTQfy7uO3WH3pEbhkhDJbni3Ol+ITsGF6CGoAVtEN1A42fwjH08FrrmXjyjgCGCt9lp9J7EPF+4y89V4sVHicxRWWUxEf1e7w== 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=xPoC76QVmRLukWDZVRi2kq0kobxOhhCUpWdc5iRwcDs=; b=jKVLWiC2bZ1p7zdKtwtTYxWC3htM9qxboGOA/CLdqQlJa2NZGUBEkheqmzBWPbs8Lpi1FhWPp1/422cWkWmR/6zVitMpJiBpPLDzfQC1yomDnkcCwUArff/+Tj1JyfhRdvandNncv314bUoA7F84e1+gw+7q6JSqgL/TRaFoY9EKMGcA/22axr6drCXHF4ZrxnSkqepnJKp9XTFMxhxeduSAlsD3eKXoBMttl+Of9A4GimecQLYWBBrsxtUHBmU/n7KZybP2tz1l2kkryhmqMLqK/X900A9pjeSTO1ifOzIRCilR7oBfEFEMJ3L4XQO4SXP2bYq1TZdtfCY7Istasg== 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xPoC76QVmRLukWDZVRi2kq0kobxOhhCUpWdc5iRwcDs=; b=o/FQ4+doXcl27K+8OgY53LsNJ/82ghK2X/0jz8wGhUs+Kvjps1wMG8AqQ+iMBgjtY/slLX4mzikU2wloV+mwEjF2B1hUIF4Lcyd5ogNLL3K388L+DFK1I6GyXkMX5+BcoosLIMVkG6gURRyYIM89YMBIACOm/nVSzkpCB+lugZI= Received: from DM6PR11MB2537.namprd11.prod.outlook.com (2603:10b6:5:cd::16) by DM6PR11MB3578.namprd11.prod.outlook.com (2603:10b6:5:143::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2921.29; Tue, 21 Apr 2020 09:44:59 +0000 Received: from DM6PR11MB2537.namprd11.prod.outlook.com ([fe80::7c08:b4ae:e9c2:a4fa]) by DM6PR11MB2537.namprd11.prod.outlook.com ([fe80::7c08:b4ae:e9c2:a4fa%6]) with mapi id 15.20.2921.030; Tue, 21 Apr 2020 09:44:59 +0000 From: "Iremonger, Bernard" To: "Guo, Jia" , "orika@mellanox.com" , "Ye, Xiaolong" , "Zhang, Qi Z" CC: "dev@dpdk.org" , "Wu, Jingjing" , "Cao, Yahui" , "Su, Simei" Thread-Topic: [dpdk-dev v7 3/3] app/testpmd: add new types to RSS hash commands Thread-Index: AQHWFIH9Wnk5yvfGEkuRo6TswIXvQKiDWFeg Date: Tue, 21 Apr 2020 09:44:58 +0000 Message-ID: References: <20200318170401.7938-5-jia.guo@intel.com> <20200417183146.112672-1-jia.guo@intel.com> <20200417183146.112672-4-jia.guo@intel.com> In-Reply-To: <20200417183146.112672-4-jia.guo@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.2.0.6 authentication-results: spf=none (sender IP is ) smtp.mailfrom=bernard.iremonger@intel.com; x-originating-ip: [192.198.151.179] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 18871dc5-73c1-46eb-8b8f-08d7e5d8a815 x-ms-traffictypediagnostic: DM6PR11MB3578: x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2449; x-forefront-prvs: 038002787A x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR11MB2537.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(10019020)(346002)(396003)(39860400002)(366004)(136003)(376002)(6636002)(7696005)(478600001)(316002)(54906003)(110136005)(33656002)(8936002)(81156014)(86362001)(8676002)(53546011)(66476007)(52536014)(66446008)(64756008)(66556008)(186003)(76116006)(66946007)(2906002)(107886003)(4326008)(26005)(9686003)(55016002)(6506007)(5660300002)(71200400001); DIR:OUT; SFP:1102; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: /CEPJZsCWDu9n02E+ArM8XYodvhGQQSbyR0bMdWq9PZ/pq2wuhJYnptxzsM1zeUGjQVt3HvpdiGFwdVXBVkumppTKXG2Fg1o1SXBdwBI4BOwA2hYR/37J4vsD/nlBFrNfS5f4apa/033zmf3xPBaXkMpaXL5obmvk8234pv17W7mX1lmeK1Egt8pdN3fWK3oPtwPSGcUPYC/AuWC4NUj/zNQ4QX7gdUeQSOSBDadcoTQQVuaEh78mk0i1AWfgeqFF8AoAaOAJJeJtOIeuC8nUlyh/9lYQFsj3HKisuyDJJ14LZnQ78EI+h565LoT+bSxRddweC3WnIMvFlJQSAK9C+s/KhnpCN4iMhyn6EbeaUlB8XkGPXFgJ+e+Bi0PxQ3cYxLc0EiPt/Ff5Z0JZXzzarzBDBTdM8bMTEoyERVgMVKjF7nvr7hVJJT0rAgQhvd3 x-ms-exchange-antispam-messagedata: U3KgJmtjOl1K9aJgfIlceH3ruNUUlvESlYMuYOfoQ9g7YE7ELxZoKsuquk1alJMY3za6wixLZnRFqI1jbpzPYWkQBzc7cdULl2XoWm5EPQV1rPxqRowO6LqMj8f5NQV5eFGYjNyjDJ0suF5Wx+KcTg== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 18871dc5-73c1-46eb-8b8f-08d7e5d8a815 X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Apr 2020 09:44:58.9007 (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: nBkvNy8/nhwor5IcNOhkowGZ6XR7zLqWFsikAY/9NQeoDz/rgBIIWnEvBjm6bITLuGgXUc1HAZlqjaMeTf9vV5+N/SfcJbENDzPjgqvZfdw= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB3578 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [dpdk-dev v7 3/3] app/testpmd: add new types to RSS hash commands X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi Jeff, > -----Original Message----- > From: Guo, Jia > Sent: Friday, April 17, 2020 7:32 PM > To: Iremonger, Bernard ; > orika@mellanox.com; Ye, Xiaolong ; Zhang, Qi Z > > Cc: dev@dpdk.org; Wu, Jingjing ; Cao, Yahui > ; Su, Simei ; Guo, Jia > > Subject: [dpdk-dev v7 3/3] app/testpmd: add new types to RSS hash > commands >=20 > Add some new types, such as eth/l2-src-only/l2-dst-only/svlan/cvlan/ > l2tpv3/esp/ah/pfcp types into RSS hash commands, it could be used to > configure these rss input set by cmdline. >=20 > Example flow commands was: > testpmd>flow create 0 ingress pattern eth / ipv4 / l2tpv3oip / end \ > actions rss types l2tpv3 end key_len 0 queues end / end >=20 > port config commands was: > testpmd>port config all rss l2tpv3 >=20 > Signed-off-by: Jeff Guo > --- > v7->v6: > add missing type > add change in doc for port rss configure > --- > app/test-pmd/cmdline.c | 34 +++++++++++++++++---- > app/test-pmd/config.c | 14 +++++++-- > doc/guides/testpmd_app_ug/testpmd_funcs.rst | 2 +- > 3 files changed, 40 insertions(+), 10 deletions(-) >=20 > diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index > 982322c35..97cf6ee35 100644 > --- a/app/test-pmd/cmdline.c > +++ b/app/test-pmd/cmdline.c > @@ -2270,9 +2270,14 @@ cmd_config_rss_parsed(void *parsed_result, > int ret; >=20 > if (!strcmp(res->value, "all")) > - rss_conf.rss_hf =3D ETH_RSS_IP | ETH_RSS_TCP | > - ETH_RSS_UDP | ETH_RSS_SCTP | > - ETH_RSS_L2_PAYLOAD; > + rss_conf.rss_hf =3D ETH_RSS_ETH | ETH_RSS_VLAN | > ETH_RSS_IP | > + ETH_RSS_TCP | ETH_RSS_UDP | ETH_RSS_SCTP | > + ETH_RSS_L2_PAYLOAD | ETH_RSS_L2TPV3 | > ETH_RSS_ESP | > + ETH_RSS_AH | ETH_RSS_PFCP; > + else if (!strcmp(res->value, "eth")) > + rss_conf.rss_hf =3D ETH_RSS_ETH; > + else if (!strcmp(res->value, "vlan")) > + rss_conf.rss_hf =3D ETH_RSS_VLAN; > else if (!strcmp(res->value, "ip")) > rss_conf.rss_hf =3D ETH_RSS_IP; > else if (!strcmp(res->value, "udp")) > @@ -2299,6 +2304,18 @@ cmd_config_rss_parsed(void *parsed_result, > rss_conf.rss_hf =3D ETH_RSS_L4_SRC_ONLY; > else if (!strcmp(res->value, "l4-dst-only")) > rss_conf.rss_hf =3D ETH_RSS_L4_DST_ONLY; > + else if (!strcmp(res->value, "l2-src-only")) > + rss_conf.rss_hf =3D ETH_RSS_L2_SRC_ONLY; > + else if (!strcmp(res->value, "l2-dst-only")) > + rss_conf.rss_hf =3D ETH_RSS_L2_DST_ONLY; > + else if (!strcmp(res->value, "l2tpv3")) > + rss_conf.rss_hf =3D ETH_RSS_L2TPV3; > + else if (!strcmp(res->value, "esp")) > + rss_conf.rss_hf =3D ETH_RSS_ESP; > + else if (!strcmp(res->value, "ah")) > + rss_conf.rss_hf =3D ETH_RSS_AH; > + else if (!strcmp(res->value, "pfcp")) > + rss_conf.rss_hf =3D ETH_RSS_PFCP; > else if (!strcmp(res->value, "none")) > rss_conf.rss_hf =3D 0; > else if (!strcmp(res->value, "default")) @@ -2359,7 +2376,8 @@ > cmdline_parse_inst_t cmd_config_rss =3D { > .f =3D cmd_config_rss_parsed, > .data =3D NULL, > .help_str =3D "port config all rss " > - > "all|default|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|vxla > n-gpe|none|", > + > "all|default|eth|vlan|ip|tcp|udp|sctp|ether|port|vxlan|geneve|" > + "nvgre|vxlan- > gpe|l2tpv3|esp|ah|pfcp|none|", > .tokens =3D { > (void *)&cmd_config_rss_port, > (void *)&cmd_config_rss_keyword, > @@ -2469,7 +2487,9 @@ cmdline_parse_token_string_t > cmd_config_rss_hash_key_rss_type =3D > "ipv4-other#ipv6#ipv6-frag#ipv6-tcp#ipv6- > udp#" > "ipv6-sctp#ipv6-other#l2-payload#ipv6-ex#" > "ipv6-tcp-ex#ipv6-udp-ex#" > - "l3-src-only#l3-dst-only#l4-src-only#l4-dst- > only"); > + "l3-src-only#l3-dst-only#l4-src-only#l4-dst- > only#" > + "l2-src-only#l2-dst-only#s-vlan#c-vlan#" > + "l2tpv3#esp#ah#pfcp"); > cmdline_parse_token_string_t cmd_config_rss_hash_key_value =3D > TOKEN_STRING_INITIALIZER(struct cmd_config_rss_hash_key, key, > NULL); >=20 > @@ -2480,7 +2500,9 @@ cmdline_parse_inst_t cmd_config_rss_hash_key =3D > { > "ipv4|ipv4-frag|ipv4-tcp|ipv4-udp|ipv4-sctp|ipv4-other|" > "ipv6|ipv6-frag|ipv6-tcp|ipv6-udp|ipv6-sctp|ipv6-other|" > "l2-payload|ipv6-ex|ipv6-tcp-ex|ipv6-udp-ex|" > - "l3-src-only|l3-dst-only|l4-src-only|l4-dst-only " > + "l3-src-only|l3-dst-only|l4-src-only|l4-dst-only|" > + "l2-src-only|l2-dst-only|s-vlan|c-vlan|" > + "l2tpv3|esp|ah|pfcp " > "", > .tokens =3D { > (void *)&cmd_config_rss_hash_key_port, diff --git > a/app/test-pmd/config.c b/app/test-pmd/config.c index > 69c5633e8..72f25d152 100644 > --- a/app/test-pmd/config.c > +++ b/app/test-pmd/config.c > @@ -75,10 +75,16 @@ static const struct { }; >=20 > const struct rss_type_info rss_type_table[] =3D { > - { "all", ETH_RSS_IP | ETH_RSS_TCP | > - ETH_RSS_UDP | ETH_RSS_SCTP | > - ETH_RSS_L2_PAYLOAD }, > + { "all", ETH_RSS_ETH | ETH_RSS_VLAN | ETH_RSS_IP | ETH_RSS_TCP > | > + ETH_RSS_UDP | ETH_RSS_SCTP | ETH_RSS_L2_PAYLOAD | > + ETH_RSS_L2TPV3 | ETH_RSS_ESP | ETH_RSS_AH | > ETH_RSS_PFCP}, > { "none", 0 }, > + { "eth", ETH_RSS_ETH }, > + { "l2-src-only", ETH_RSS_L2_SRC_ONLY }, > + { "l2-dst-only", ETH_RSS_L2_DST_ONLY }, > + { "vlan", ETH_RSS_VLAN }, > + { "s-vlan", ETH_RSS_S_VLAN }, > + { "c-vlan", ETH_RSS_C_VLAN }, > { "ipv4", ETH_RSS_IPV4 }, > { "ipv4-frag", ETH_RSS_FRAG_IPV4 }, > { "ipv4-tcp", ETH_RSS_NONFRAG_IPV4_TCP }, @@ -110,6 +116,8 @@ > const struct rss_type_info rss_type_table[] =3D { > { "l4-dst-only", ETH_RSS_L4_DST_ONLY }, > { "esp", ETH_RSS_ESP }, > { "ah", ETH_RSS_AH }, > + { "l2tpv3", ETH_RSS_L2TPV3 }, > + { "pfcp", ETH_RSS_PFCP }, > { NULL, 0 }, > }; >=20 > diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst > b/doc/guides/testpmd_app_ug/testpmd_funcs.rst > index dcee5de45..2928499b6 100644 > --- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst > +++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst > @@ -2199,7 +2199,7 @@ port config - RSS >=20 > Set the RSS (Receive Side Scaling) mode on or off:: >=20 > - testpmd> port config all rss > (all|default|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|vxlan- > gpe|none) > + testpmd> port config all rss > + > (all|default|eth|vlan|ip|tcp|udp|sctp|ether|port|vxlan|geneve|nvgre|vx > + lan-gpe|l2tpv3|esp|ah|pfcp|none) >=20 > RSS is on by default. The "all" option needs to be updated with the latest "all" values. It would also be good to reformat the text so that the "all", "none" and "d= efault" options are on separate lines. >=20 > -- > 2.20.1 Regards, Bernard.