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 29884A0548 for ; Sun, 20 Jun 2021 16:15:35 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E87784003F; Sun, 20 Jun 2021 16:15:34 +0200 (CEST) Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1anam02on2065.outbound.protection.outlook.com [40.107.96.65]) by mails.dpdk.org (Postfix) with ESMTP id E276F4003F for ; Sun, 20 Jun 2021 16:15:33 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=chY4/EyeRwiXjJNSMFahIRNgdCCuNRqTauRBo9tnIFjLCYX1HHgTQAiACuPnD2W1J3+mYxTHBHC4rBu0akY2Q0vz/ke8VHvy6FOloaT9m1l0n8+/e6ZyKCf5NktJRAYJMCH4Y+CN3o8dW4jhggcUFwLvpnbUWfmA/eeBBPlSbDGqFwaaODIb9oaRpCTgf0B6KluiDslcSd1pObU3Od/jqJCGg9PHAR5DsGmbdvLo9UZlCizzqoTG2k5qFdRmONLhoYLWT6z89Ezb/GE062kUmG0WKIpfjx7OBS+oT+SUksCvUSoe7bf+c9kPDi6dXOzLFhi9LyQlPj424PYo0UoBmQ== 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=ICp1u1SYHDtORB//LmSTRmTSvon1jTDjqOLndQqN/Xg=; b=DF1mpp/WzpyH9y6Ii/PlPDH4y9hV5+LOwx3xJBm7xtbcixVQnJD1zbxbKoxvMXfP9IZbHw6OgG/ptO77RNtFNcxSEANdZXOKqS3qvobT+OEpWfSBUsjHZIFTksZIIGYFWWWkhVA+duJHW8yaJ8K9n0i+zZi3rnGmpCIcGJKlZ/sCwGy9Pl65KvLAmXDeUxOHXgQqZP8oxmPJPHihbFcqGj6x5/o8knZHQ2Tn5XFIPNEE5XRkz9gHKLRu0LDljAQ4syaWnwh9KPql0PAF+d+/1dffeQ+0MbHF11f0WUhD3eVC5EPnA41XMb7mQBuGTH7WozuIiFbFY5GOttsylfSDkA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ICp1u1SYHDtORB//LmSTRmTSvon1jTDjqOLndQqN/Xg=; b=YHMPi9oj5EGxfEiAp/v623IlqV6vjdjBSbJ7rqBcmCYRTjEhOOd9/xfUrtMWkSj7H3Ujjyj13UYpYxFA7WSoPkNETELV/Y3Y+P4VEVwt2R9M9dtd+qYJ+RN8bTq2JR2Dm9wPOXyQZk5yk2Y8fkSP0BHrRw/SSve4pA7lD0B0lofHCPwuIiKiPNDgeBSinSpgGZj0BQgV5tupoL94XZksZHdnnUDLk27kaxmi6ZWloly06PSteDqYCtX0cI29IZYgPK/45e/SR5igU6poQSgIha+P/gN+CgM32bZu60fYtUZcRFtlT2Cc+l/LbvPU1lQOqSWYIkrKRfwULd6Bt/C2DQ== Received: from DM4PR12MB5373.namprd12.prod.outlook.com (2603:10b6:5:39a::17) by DM8PR12MB5429.namprd12.prod.outlook.com (2603:10b6:8:29::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4242.16; Sun, 20 Jun 2021 14:15:32 +0000 Received: from DM4PR12MB5373.namprd12.prod.outlook.com ([fe80::ac75:9b9a:a03f:1676]) by DM4PR12MB5373.namprd12.prod.outlook.com ([fe80::ac75:9b9a:a03f:1676%3]) with mapi id 15.20.4242.023; Sun, 20 Jun 2021 14:15:32 +0000 From: "Xueming(Steven) Li" To: Wenjun Wu , "stable@dpdk.org" , "qiming.yang@intel.com" , "qi.z.zhang@intel.com" Thread-Topic: [dpdk-stable] [PATCH 20.11] net/ice: fix RSS for L2 packet Thread-Index: AQHXYybP1vtKd/gBvEqVf6o1P+ylmqsc9wGg Date: Sun, 20 Jun 2021 14:15:32 +0000 Message-ID: References: <20210617025623.1026715-1-wenjun1.wu@intel.com> In-Reply-To: <20210617025623.1026715-1-wenjun1.wu@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=nvidia.com; x-originating-ip: [180.174.129.228] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 9b87b5f5-1f49-4a3b-f772-08d933f5dd51 x-ms-traffictypediagnostic: DM8PR12MB5429: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2887; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: kfi/qnCdGEnUApp2ZL0ZYKPT0bV6sr79UVpINRyoaLmrbaWwp3x3h4h2QUvQI87HeV7qOHPrtlDdCetF17eKJREXuj/pegaG+zD8GsPwT+VFBagduPN1AUb2ThV9yqzPOkGA/HlsNgTthsshw40QR8FnT6CcaCsi495+8wOEagx1unsd39bLQb1YhqjpOD0cFBa1sC434yHQiYDBi3nuddxZeGMzly1MHtCKC/Ncjh/0Qx41I7WzlHAyyTj0KRh6jFZJ8dw5VHeVwVazhBsYNYXT97+dm6EVIi2CCiwZA+JlyOvsVfXnfTd/u404aLAEhQrverunAKMhEEsJrB4bl4jj8737UPpAVKoFq760lPn5YlkUgr0uFjl8bUj06LKFXQgwWJG0herbD83/Y6e4J0Ss99O1Ty2kfpS5ZYNUb8azkx9xTI/2V5ZwejX+b6GfFOb7hHFx7ZWk/tM3REkGKxP33dRKDLIS0G0SJDKdUwmRyftZvr2+2J4eSkgF6AWFJJOFzeR7pbnRW5SWV1MSTpEH9VsywQCesxW0Mr5xczer7k4LTazfLU/KE/40vdLaIHiRfyomgyf4tzlO0dQT0hG41f6YlHNWpnWM0wtfoDegEZi3WcPu7toF4umsp263CV9GtpsiPYbZ6AC9MkJT+z7JM3JePI11ipB9w6jXtov911qmQkpavVoPY6pOAI14pQ0xpamv7HMEBm69pdJbSexXfBx/4iSvFRGMmhuT1Hc= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM4PR12MB5373.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(346002)(366004)(39860400002)(376002)(136003)(396003)(26005)(7696005)(66446008)(6506007)(53546011)(478600001)(52536014)(76116006)(186003)(122000001)(71200400001)(316002)(110136005)(83380400001)(8936002)(8676002)(86362001)(55016002)(64756008)(66476007)(66946007)(966005)(2906002)(38100700002)(9686003)(33656002)(5660300002)(66556008); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?gxjg/d5pNk1L1ZPCcjBrm8xrwMm+kCJXwPBqnCJSy53yAPDpHMhhgeRMZZSg?= =?us-ascii?Q?/aF70t/nzDNYDzbXgiheksl5m7U3psOmwbh0+KGPjfwYqbx0gtpHOk+I+s9/?= =?us-ascii?Q?lwBqBx5BFLkyo05Lc28wySrL4VT4gJMQWFzf/cK6ncrK7Y9RnikqdSzkIBpH?= =?us-ascii?Q?R3OP8a0caGgbVapwnvCrKpiP6w5JtPe4cGlvTyG9VWQ0VD4LuwWvMdocJSyu?= =?us-ascii?Q?dca5GzIAd7od4V7jwXa11zVVxx+QqeAiYop4nYRurD6kNPZtkeEoAi43dIX7?= =?us-ascii?Q?8OVKBYPLARhXktnk309dU2uvF2lBUZBTx7QN5itPSh5h0TvfL34i1Bu+lO3o?= =?us-ascii?Q?YBUq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ssrP7bvLM1pehWu?= =?us-ascii?Q?l5hUi5fk67dkOSqIkb4MbGaPWyv7EO42DhMd2qsKKCfu9/Di5yYi913lkXvb?= =?us-ascii?Q?bTUN8CC5W43dPMBi05zhu9XU?= x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM4PR12MB5373.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9b87b5f5-1f49-4a3b-f772-08d933f5dd51 X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Jun 2021 14:15:32.1671 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: cfIuMFNW18JLl1QEihJ1DV2FEi2k6GIS9rUfDEUYimAA9eulyc4ef5Xm/dPRNg4XZRaMOR9kXhAj90nFVMSiew== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM8PR12MB5429 Subject: Re: [dpdk-stable] [PATCH 20.11] net/ice: fix RSS for L2 packet X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Applied, thanks for the backport > -----Original Message----- > From: stable On Behalf Of Wenjun Wu > Sent: Thursday, June 17, 2021 10:56 AM > To: stable@dpdk.org; qiming.yang@intel.com; qi.z.zhang@intel.com > Cc: Wenjun Wu > Subject: [dpdk-stable] [PATCH 20.11] net/ice: fix RSS for L2 packet >=20 > RSS support for L2 non-ip packets is missing in previous versions. >=20 > However, due to code refactor, the fix [1] in main branch cannot be appli= ed directly. This patch fixes this issue in stable versions. >=20 > [1] https://patchwork.dpdk.org/patch/94066/ >=20 > Fixes: 5ad3db8d4bdd ("net/ice: enable advanced RSS") >=20 > Signed-off-by: Wenjun Wu > --- > drivers/net/ice/base/ice_flow.c | 2 +- > drivers/net/ice/ice_hash.c | 14 ++++++++++++++ > 2 files changed, 15 insertions(+), 1 deletion(-) >=20 > diff --git a/drivers/net/ice/base/ice_flow.c b/drivers/net/ice/base/ice_f= low.c index 548d998546..c75f58659c 100644 > --- a/drivers/net/ice/base/ice_flow.c > +++ b/drivers/net/ice/base/ice_flow.c > @@ -3233,7 +3233,7 @@ ice_flow_add_fld_raw(struct ice_flow_seg_info *seg,= u16 off, u8 len, } >=20 > #define ICE_FLOW_RSS_SEG_HDR_L2_MASKS \ -(ICE_FLOW_SEG_HDR_ETH | ICE_FLO= W_SEG_HDR_VLAN) > +(ICE_FLOW_SEG_HDR_ETH | ICE_FLOW_SEG_HDR_ETH_NON_IP | > +ICE_FLOW_SEG_HDR_VLAN) >=20 > #define ICE_FLOW_RSS_SEG_HDR_L3_MASKS \ > (ICE_FLOW_SEG_HDR_IPV4 | ICE_FLOW_SEG_HDR_IPV6) diff --git a/drivers/ne= t/ice/ice_hash.c b/drivers/net/ice/ice_hash.c > index fe3e06c579..1bb7d2c7c6 100644 > --- a/drivers/net/ice/ice_hash.c > +++ b/drivers/net/ice/ice_hash.c > @@ -312,6 +312,9 @@ struct rss_type_match_hdr hint_eth_pppoes_ipv6_tcp = =3D { struct rss_type_match_hdr hint_eth_pppoes =3D { > ICE_FLOW_SEG_HDR_PPPOE, > ETH_RSS_ETH | ETH_RSS_PPPOE}; > +struct rss_type_match_hdr hint_ethertype =3D { > + ICE_FLOW_SEG_HDR_ETH | ICE_FLOW_SEG_HDR_ETH_NON_IP, > + ETH_RSS_ETH}; >=20 > /* Supported pattern for os default package. */ static struct ice_patte= rn_match_item ice_hash_pattern_list_os[] =3D { @@ -444,6 > +447,8 @@ static struct ice_pattern_match_item ice_hash_pattern_list_comm= s[] =3D { > &hint_eth_pppoes_ipv6_tcp}, > {pattern_eth_pppoes, ICE_INSET_NONE, > &hint_eth_pppoes}, > + {pattern_ethertype, ICE_INSET_NONE, > + &hint_ethertype}, > }; >=20 > /** > @@ -1140,6 +1145,15 @@ ice_hash_parse_action(struct ice_pattern_match_ite= m *pattern_match_item, > "Not supported flow"); > } >=20 > + /* update hash field for eth-non-ip. */ > + if (rss_type & ETH_RSS_ETH) { > + if (hash_meta->pkt_hdr & > + ICE_FLOW_SEG_HDR_ETH_NON_IP) { > + hash_meta->hash_flds |=3D > + BIT_ULL(ICE_FLOW_FIELD_IDX_ETH_TYPE); > + } > + } > + > /* update hash field for nat-t esp. */ > if (rss_type & ETH_RSS_ESP && > (m->eth_rss_hint & ETH_RSS_NONFRAG_IPV4_UDP || > -- > 2.25.1