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 3FC43A00BE; Fri, 1 Nov 2019 18:50:05 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id F296E1E565; Fri, 1 Nov 2019 18:50:02 +0100 (CET) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id B0A341E55F for ; Fri, 1 Nov 2019 18:50:01 +0100 (CET) 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 xA1HjIid020226; Fri, 1 Nov 2019 10:49:48 -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=Ev+Mb93KEtk5UsZcvKjA3Exq6C/aSBghnYTeHWWmJ+8=; b=tPY6xbEYKo6iL3C5BRJEAOuAKw2EE+9J+/fwvIqh8Xv31dhTay2flISlGebe2e/3v/6u osreH/Va/KL+h382NO9zIdMvDhmrL3iq/CPOK1M5ZquQmLbYSVlaw2G8SNC8iETmgwlg cclkCnyX7sETlE3ueWr3/XD450BSrU40M2nw4kMM1fd5m6xevbK+qAYsn7/EhBZX+xe3 dWbSv5Q/eRsrKXRyxIZ3EPfvd/Wk2ZBQ7l2lkUeMdCjqWiYByfipkNNRvGI8/pd+EiRS 0GKvGYNlPS0IrcVo4tEYzJNwPcOfZv0loJxXI69yCQn0YGZOYVuB6CwJkMTgLL6yw++5 8A== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0a-0016f401.pphosted.com with ESMTP id 2vxwjmcwhb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 01 Nov 2019 10:49:47 -0700 Received: from SC-EXCH04.marvell.com (10.93.176.84) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Fri, 1 Nov 2019 10:49:46 -0700 Received: from NAM03-DM3-obe.outbound.protection.outlook.com (104.47.41.50) by SC-EXCH04.marvell.com (10.93.176.84) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Fri, 1 Nov 2019 10:49:46 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HMwp+RljVcSOY5cmmbmoNDDW+98B5/I5QGGNQmd4drxfCzEIEHyWNe4S+bRUNMgvk0UTyH9IW+qwMqaFCgjM0m/IaM9GYOJX2/XTFndFyypYjtqiMpWZrK5tqoqTstXHRTMJXkA+vV5LwD6i6Y6nMcwN21xegy4llZphkvow5VZ5Cev0fIrx/URrsWCei+cgNsfePJ+gUsxVacu2aKw08iA4pumeg/w3tU0ZXG/s2myw2KY3Gu5dECr7glA1z3Pooe78JzxY+ddnMtATWVsCrAQ13DO7hnK8aeeSqHQgDFZaeu9NaxUARL6SX2WGQ1Ia6FCCgFsnekcxGOqWlvLmqg== 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=Ev+Mb93KEtk5UsZcvKjA3Exq6C/aSBghnYTeHWWmJ+8=; b=h94d0pNtabb9l8SZmf6PunmyK4fgEVwTlYBIefuqh7hMG1wedkum4EeNG0cU70cED8Z5ALRUyrCHwi24TmWAutueaWKqQHcinf6ChCGpRaegEv3bWpSiEs0hVxLGe+y9Zt9NKFjFijyaUibsRyfs6Dy7b3jAUDZVQ2ubkOzJwJIF6CAMcA4TxRX1cwF5dSFfhtCL2Tcjx+IbSG/CJMvz4Nw8Atp+RweDKxLBeipxmybfuoCkBuhOJOpD4mmU/4nYCcih/4szezeDEyhBGYGwePyGv+Omk4w5diniKngSDZSTUkqFoF2l/3kqPmxuKo7X/ZKQ37plmlx1ewcPon/KKg== 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=Ev+Mb93KEtk5UsZcvKjA3Exq6C/aSBghnYTeHWWmJ+8=; b=JZt551w3pA56L8qIYdTjVke9AEaCb4aoH7g+OgNqK7NNsMVMkC0i3XauRTIfd9Ln8vGnIGSplyA3csbA3jGVDssUVgJ2VBeWRTlZc1rEcgzAz7gV3e4Y/KQw5YCCEJp1uMguaeBDvTsPsicshlP5K8+GoOoamPFNKfYb+vyH8jA= Received: from MN2PR18MB2398.namprd18.prod.outlook.com (20.179.81.144) by MN2PR18MB2477.namprd18.prod.outlook.com (20.179.81.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2387.22; Fri, 1 Nov 2019 17:49:44 +0000 Received: from MN2PR18MB2398.namprd18.prod.outlook.com ([fe80::b5e6:b111:3f90:6a7]) by MN2PR18MB2398.namprd18.prod.outlook.com ([fe80::b5e6:b111:3f90:6a7%6]) with mapi id 15.20.2387.027; Fri, 1 Nov 2019 17:49:44 +0000 From: Liron Himi To: Pavan Nikhilesh Bhagavatula , "ferruh.yigit@intel.com" , "arybchenko@solarflare.com" , "Jerin Jacob Kollanukkaran" , Ajit Khaparde , Somnath Kotur , Rahul Lakkireddy , Hemant Agrawal , Sachin Saxena , Wenzhuo Lu , John Daley , Hyong Youb Kim , Qi Zhang , Xiao Wang , Ziyang Xuan , Xiaoyun Wang , Guoyang Zhou , "Beilei Xing" , Jingjing Wu , "Qiming Yang" , Konstantin Ananyev , Shijith Thotton , Srisivasubramanian Srinivasan , Matan Azrad , Shahaf Shuler , "Viacheslav Ovsiienko" , Stephen Hemminger , "K. Y. Srinivasan" , "Haiyang Zhang" , Alejandro Lucero , Nithin Kumar Dabilpuram , Kiran Kumar Kokkilagadda , Rasesh Mody , Shahed Shaikh , Maciej Czekaj , Yong Wang CC: "dev@dpdk.org" , Pavan Nikhilesh Bhagavatula , Liron Himi Thread-Topic: [dpdk-dev] [PATCH v15 4/7] drivers/net: update Rx RSS hash offload capabilities Thread-Index: AQHVjm70N+2rITyc9EiCzZBEiHEwW6d2nA0Q Date: Fri, 1 Nov 2019 17:49:43 +0000 Message-ID: References: <20191029050312.2715-1-pbhagavatula@marvell.com> <20191029153722.4547-1-pbhagavatula@marvell.com> <20191029153722.4547-5-pbhagavatula@marvell.com> In-Reply-To: <20191029153722.4547-5-pbhagavatula@marvell.com> Accept-Language: he-IL, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [85.250.105.60] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 5f6bdafe-81b1-4a61-9292-08d75ef3e106 x-ms-traffictypediagnostic: MN2PR18MB2477: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:10000; x-forefront-prvs: 020877E0CB x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(396003)(136003)(346002)(39850400004)(376002)(366004)(13464003)(189003)(199004)(1511001)(7416002)(3846002)(15650500001)(66556008)(26005)(6116002)(66446008)(9686003)(76116006)(2501003)(446003)(74316002)(2201001)(7736002)(305945005)(11346002)(6436002)(229853002)(2906002)(55016002)(64756008)(86362001)(8936002)(66946007)(71200400001)(186003)(81156014)(316002)(30864003)(66476007)(71190400001)(81166006)(54906003)(476003)(53546011)(107886003)(7696005)(5660300002)(6506007)(33656002)(256004)(478600001)(25786009)(99286004)(76176011)(66066001)(102836004)(52536014)(6246003)(14444005)(14454004)(4326008)(486006)(110136005)(921003)(1121003)(559001)(579004); DIR:OUT; SFP:1101; SCL:1; SRVR:MN2PR18MB2477; H:MN2PR18MB2398.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: HSP2T8l/rO5snm4q/NH1yutZx/yjiXaGjx2k7HsXXrU6QSKVY1w8nxQ+Rl2OAuGOCBC76fOL3uMsK/pu6FyOFbpsMxaQHcQb8Oqfq9m4a0vfcchIp7xQpdb9uzxwCg8VWOx7JyVY/yPJoPI1iy1nm16oR728P5Fnqf65AYAJqm4aZPsZZ7+WO6O78Wmu1aNQBiJbf7GvedXQnHu1t2lA1jftMGnB288A6fMV9MIz13i6HXr0JMoj4qB/CtDxIah3+AYr2lNBNv6KyY25RDJx4vITJSvQYA5m4ya+UeSc1mxcrZbwBzFQHdYsYLXrKFyXC3o99UcY7ywv5VazwRJDmFImtj5t7LxDgsOCah8uLZ9dkKRYJkL0ZG/D1gKd2e+gd+BIpTVa7qAVyLgz+wQYxDCFuh+vo7XrD3eBxyrVW6STVbTv/959xPfi0MXSd2ln Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 5f6bdafe-81b1-4a61-9292-08d75ef3e106 X-MS-Exchange-CrossTenant-originalarrivaltime: 01 Nov 2019 17:49:43.7844 (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: wQAgg7olnptafs3SybGucdXfa2qChCAX5DZM7Q4KtI2yIrGnPY4e5hNiaHvyLryjf672ljqaEWi/VjXbjmz25A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR18MB2477 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.95,1.0.8 definitions=2019-11-01_06:2019-11-01,2019-11-01 signatures=0 Subject: Re: [dpdk-dev] [PATCH v15 4/7] drivers/net: update Rx RSS hash offload capabilities 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, mvpp2 and mvneta PMDs are also support RSS hash. Please add them to the patch. Regards, Liron -----Original Message----- From: dev On Behalf Of pbhagavatula@marvell.com Sent: Tuesday, 29 October 2019 17:37 To: ferruh.yigit@intel.com; arybchenko@solarflare.com; Jerin Jacob Kollanuk= karan ; Ajit Khaparde ; Som= nath Kotur ; Rahul Lakkireddy ; Hemant Agrawal ; Sachin Saxena ; Wenzhuo Lu ; John Daley ; Hyong Youb Kim ; Qi Zhang ; Xiao Wang ; Ziyang Xuan ; Xiaoyun Wang ; Guoyang Zhou ; Beilei Xing ; Jingjing Wu ; Qiming Yang ; Konstantin Ananyev ; Shijith Thotton ; Srisivasu= bramanian Srinivasan ; Matan Azrad ; Shahaf Shuler ; Viacheslav Ovsiienko ; Stephen Hemminger ; K. Y. Sriniva= san ; Haiyang Zhang ; Alejandro = Lucero ; Nithin Kumar Dabilpuram ; Kiran Kumar Kokkilagadda ; Rasesh= Mody ; Shahed Shaikh ; Maciej Cze= kaj ; Yong Wang Cc: dev@dpdk.org; Pavan Nikhilesh Bhagavatula Subject: [dpdk-dev] [PATCH v15 4/7] drivers/net: update Rx RSS hash offload= capabilities From: Pavan Nikhilesh Add DEV_RX_OFFLOAD_RSS_HASH flag for all PMDs that support RSS hash deliver= y. Signed-off-by: Pavan Nikhilesh Reviewed-by: Andrew Rybchenko Reviewed-by: Hemant Agrawal Acked-by: Jerin Jacob Acked-by: Ajit Khaparde --- drivers/net/bnxt/bnxt_ethdev.c | 8 +++++++- drivers/net/cxgbe/cxgbe.h | 3 ++- drivers/net/cxgbe/cxgbe_ethdev.c | 5 +++++ drivers/net/dpaa/dpaa_ethdev.c | 3 ++- drivers/net/dpaa2/dpaa2_ethdev.c | 1 + drivers/net/e1000/igb_ethdev.c | 6 ++++++ drivers/net/e1000/igb_rxtx.c | 3 ++- drivers/net/enic/enic_ethdev.c | 5 +++++ drivers/net/enic/enic_res.c | 3 ++- drivers/net/fm10k/fm10k_ethdev.c | 6 +++++- drivers/net/hinic/hinic_pmd_ethdev.c | 6 +++++- drivers/net/i40e/i40e_ethdev.c | 6 +++++- drivers/net/iavf/iavf_ethdev.c | 6 +++++- drivers/net/ice/ice_ethdev.c | 6 +++++- drivers/net/ixgbe/ixgbe_ethdev.c | 7 +++++++ drivers/net/ixgbe/ixgbe_rxtx.c | 3 ++- drivers/net/liquidio/lio_ethdev.c | 7 ++++++- drivers/net/mlx4/mlx4.c | 3 +++ drivers/net/mlx4/mlx4_rxq.c | 3 ++- drivers/net/mlx5/mlx5_ethdev.c | 4 ++++ drivers/net/mlx5/mlx5_rxq.c | 3 ++- drivers/net/netvsc/hn_ethdev.c | 3 +++ drivers/net/netvsc/hn_rndis.c | 3 ++- drivers/net/nfp/nfp_net.c | 6 +++++- drivers/net/octeontx2/otx2_ethdev.c | 3 ++- drivers/net/octeontx2/otx2_= ethdev.h | 15 ++++++++------- drivers/net/qede/qede_ethdev.c | 6 +++++- drivers/net/sfc/sfc_ef10_essb_rx.c | 3 ++- drivers/net/sfc/sfc_ef10_rx.c | 3 ++- drivers/net/sfc/sfc_rx.c | 7 ++++++- drivers/net/thunderx/nicvf_ethdev.c | 3 +++ drivers/net/thunderx/nicvf_= ethdev.h | 3 ++- drivers/net/vmxnet3/vmxnet3_ethdev.c | 6 +++++- 33 files changed, 128 insertions(+), 30 deletions(-) diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.= c index 7d9459f0a..01d48f47c 100644 --- a/drivers/net/bnxt/bnxt_ethdev.c +++ b/drivers/net/bnxt/bnxt_ethdev.c @@ -123,7 +123,8 @@ static const struct rte_pci_id bnxt_pci_id_map[] =3D { DEV_RX_OFFLOAD_KEEP_CRC | \ DEV_RX_OFFLOAD_VLAN_EXTEND | \ DEV_RX_OFFLOAD_TCP_LRO | \ - DEV_RX_OFFLOAD_SCATTER) + DEV_RX_OFFLOAD_SCATTER | \ + DEV_RX_OFFLOAD_RSS_HASH) =20 static int bnxt_vlan_offload_set_op(struct rte_eth_dev *dev, int mask); s= tatic void bnxt_print_link_info(struct rte_eth_dev *eth_dev); @@ -689,6 +69= 0,11 @@ static int bnxt_dev_configure_op(struct rte_eth_dev *eth_dev) bp->rx_cp_nr_rings =3D bp->rx_nr_rings; bp->tx_cp_nr_rings =3D bp->tx_nr_rings; =20 + if (!(rx_offloads & DEV_RX_OFFLOAD_RSS_HASH)) { + rx_offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + eth_dev->data->dev_conf.rxmode.offloads =3D rx_offloads; + } + if (rx_offloads & DEV_RX_OFFLOAD_JUMBO_FRAME) { eth_dev->data->mtu =3D eth_dev->data->dev_conf.rxmode.max_rx_pkt_len - diff --git a/drivers/ne= t/cxgbe/cxgbe.h b/drivers/net/cxgbe/cxgbe.h index ed1be3559..6c1f73ac4 1006= 44 --- a/drivers/net/cxgbe/cxgbe.h +++ b/drivers/net/cxgbe/cxgbe.h @@ -47,7 +47,8 @@ DEV_RX_OFFLOAD_UDP_CKSUM | \ DEV_RX_OFFLOAD_TCP_CKSUM | \ DEV_RX_OFFLOAD_JUMBO_FRAME | \ - DEV_RX_OFFLOAD_SCATTER) + DEV_RX_OFFLOAD_SCATTER | \ + DEV_RX_OFFLOAD_RSS_HASH) =20 =20 /* Common PF and VF devargs */ diff --git a/drivers/net/cxgbe/cxgbe_ethdev.c b/drivers/net/cxgbe/cxgbe_eth= dev.c index 615dda607..6df127087 100644 --- a/drivers/net/cxgbe/cxgbe_ethdev.c +++ b/drivers/net/cxgbe/cxgbe_ethdev.c @@ -426,6 +426,11 @@ int cxgbe_dev_configure(struct rte_eth_dev *eth_dev) =20 CXGBE_FUNC_TRACE(); =20 + if (!(eth_dev->data->dev_conf.rxmode.offloads & + DEV_RX_OFFLOAD_RSS_HASH)) + eth_dev->data->dev_conf.rxmode.offloads |=3D + DEV_RX_OFFLOAD_RSS_HASH; + if (!(adapter->flags & FW_QUEUE_BOUND)) { err =3D cxgbe_setup_sge_fwevtq(adapter); if (err) diff --git a/drivers/net/dpaa/dpaa_ethdev.c b/drivers/net/dpaa/dpaa_ethdev.= c index caf255d67..096da752d 100644 --- a/drivers/net/dpaa/dpaa_ethdev.c +++ b/drivers/net/dpaa/dpaa_ethdev.c @@ -56,7 +56,8 @@ static uint64_t dev_rx_offloads_nodis =3D DEV_RX_OFFLOAD_IPV4_CKSUM | DEV_RX_OFFLOAD_UDP_CKSUM | DEV_RX_OFFLOAD_TCP_CKSUM | - DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM; + DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | + DEV_RX_OFFLOAD_RSS_HASH; =20 /* Supported Tx offloads */ static uint64_t dev_tx_offloads_sup =3D diff --git a/drivers/net/dpaa2/dpaa2_ethdev.c b/drivers/net/dpaa2/dpaa2_eth= dev.c index 03131b903..eea31f254 100644 --- a/drivers/net/dpaa2/dpaa2_ethdev.c +++ b/drivers/net/dpaa2/dpaa2_ethdev.c @@ -45,6 +45,7 @@ static uint64_t dev_rx_offloads_sup =3D =20 /* Rx offloads which cannot be disabled */ static uint64_t dev_rx_offload= s_nodis =3D + DEV_RX_OFFLOAD_RSS_HASH | DEV_RX_OFFLOAD_SCATTER; =20 /* Supported Tx offloads */ diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.= c index ce7c9e664..22665b51c 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c @@ -1182,6 +1182,9 @@ eth_igb_configure(struct rte_eth_dev *dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* multipe queue mode checking */ ret =3D igb_check_mq_mode(dev); if (ret !=3D 0) { @@ -3255,6 +3258,9 @@ igbvf_dev_configure(struct rte_eth_dev *dev) PMD_INIT_LOG(DEBUG, "Configured Virtual Function port id: %d", dev->data->port_id); =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* * VF has no ability to enable/disable HW CRC * Keep the persistent behavior the same as Host PF diff --git a/drivers/= net/e1000/igb_rxtx.c b/drivers/net/e1000/igb_rxtx.c index c5606de5d..684fa4= ad8 100644 --- a/drivers/net/e1000/igb_rxtx.c +++ b/drivers/net/e1000/igb_rxtx.c @@ -1646,7 +1646,8 @@ igb_get_rx_port_offloads_capa(struct rte_eth_dev *dev= ) DEV_RX_OFFLOAD_TCP_CKSUM | DEV_RX_OFFLOAD_JUMBO_FRAME | DEV_RX_OFFLOAD_KEEP_CRC | - DEV_RX_OFFLOAD_SCATTER; + DEV_RX_OFFLOAD_SCATTER | + DEV_RX_OFFLOAD_RSS_HASH; =20 return rx_offload_capa; } diff --git a/drivers/net/enic/enic_ethdev.c b/drivers/net/enic/enic_ethdev.= c index 12c59a3c5..d2d1488d9 100644 --- a/drivers/net/enic/enic_ethdev.c +++ b/drivers/net/enic/enic_ethdev.c @@ -405,6 +405,11 @@ static int enicpmd_dev_configure(struct rte_eth_dev *e= th_dev) return ret; } =20 + if (!(eth_dev->data->dev_conf.rxmode.offloads & + DEV_RX_OFFLOAD_RSS_HASH)) + eth_dev->data->dev_conf.rxmode.offloads |=3D + DEV_RX_OFFLOAD_RSS_HASH; + enic->mc_count =3D 0; enic->hw_ip_checksum =3D !!(eth_dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_CHECKSUM); diff --git a/drivers/net/enic/enic_res.c b/drivers/net/enic/enic_res.c inde= x f403a0b66..7c3c270a2 100644 --- a/drivers/net/enic/enic_res.c +++ b/drivers/net/enic/enic_res.c @@ -205,7 +205,8 @@ int enic_get_vnic_config(struct enic *enic) DEV_RX_OFFLOAD_VLAN_STRIP | DEV_RX_OFFLOAD_IPV4_CKSUM | DEV_RX_OFFLOAD_UDP_CKSUM | - DEV_RX_OFFLOAD_TCP_CKSUM; + DEV_RX_OFFLOAD_TCP_CKSUM | + DEV_RX_OFFLOAD_RSS_HASH; enic->tx_offload_mask =3D PKT_TX_IPV6 | PKT_TX_IPV4 | diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_eth= dev.c index 99c4366e4..2e834130d 100644 --- a/drivers/net/fm10k/fm10k_ethdev.c +++ b/drivers/net/fm10k/fm10k_ethdev.c @@ -461,6 +461,9 @@ fm10k_dev_configure(struct rte_eth_dev *dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* multipe queue mode checking */ ret =3D fm10k_check_mq_mode(dev); if (ret !=3D 0) { @@ -1805,7 +1808,8 @@ static uint64_t fm10k_get_rx_port_offloads_capa(struc= t rte_eth_dev *dev) DEV_RX_OFFLOAD_UDP_CKSUM | DEV_RX_OFFLOAD_TCP_CKSUM | DEV_RX_OFFLOAD_JUMBO_FRAME | - DEV_RX_OFFLOAD_HEADER_SPLIT); + DEV_RX_OFFLOAD_HEADER_SPLIT | + DEV_RX_OFFLOAD_RSS_HASH); } =20 static int diff --git a/drivers/net/hinic/hinic_pmd_ethdev.c b/drivers/net/hinic/hinic= _pmd_ethdev.c index 9f37a404b..6673777e9 100644 --- a/drivers/net/hinic/hinic_pmd_ethdev.c +++ b/drivers/net/hinic/hinic_pmd_ethdev.c @@ -318,6 +318,9 @@ static int hinic_dev_configure(struct rte_eth_dev *dev) return -EINVAL; } =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* mtu size is 256~9600 */ if (dev->data->dev_conf.rxmode.max_rx_pkt_len < HINIC_MIN_FRAME_SIZE || dev->data->dev_conf.rxmode.max_rx_pkt_len > @@ -740,7 +743,8 @@ hinic= _dev_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *info) DEV_RX_OFFLOAD_VLAN_FILTER | DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_JUMBO_FRAME | - DEV_RX_OFFLOAD_TCP_LRO; + DEV_RX_OFFLOAD_TCP_LRO | + DEV_RX_OFFLOAD_RSS_HASH; =20 info->tx_queue_offload_capa =3D 0; info->tx_offload_capa =3D DEV_TX_OFFLOAD_VLAN_INSERT | diff --git a/drive= rs/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c index 77a46832c.= .78fea04f8 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -1812,6 +1812,9 @@ i40e_dev_configure(struct rte_eth_dev *dev) ad->tx_simple_allowed =3D true; ad->tx_vec_allowed =3D true; =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* Only legacy filter API needs the following fdir config. So when the * legacy filter API is deprecated, the following codes should also be * removed. @@ -3613,7 +3616,8 @@ i40e_dev_info_get(struct rte_eth_dev *dev, struct rte= _eth_dev_info *dev_info) DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_VLAN_EXTEND | DEV_RX_OFFLOAD_VLAN_FILTER | - DEV_RX_OFFLOAD_JUMBO_FRAME; + DEV_RX_OFFLOAD_JUMBO_FRAME | + DEV_RX_OFFLOAD_RSS_HASH; =20 dev_info->tx_queue_offload_capa =3D DEV_TX_OFFLOAD_MBUF_FAST_FREE; dev_info->tx_offload_capa =3D diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.= c index eebc49ade..172c3f6ac 100644 --- a/drivers/net/iavf/iavf_ethdev.c +++ b/drivers/net/iavf/iavf_ethdev.c @@ -147,6 +147,9 @@ iavf_dev_configure(struct rte_eth_dev *dev) ad->rx_vec_allowed =3D true; ad->tx_vec_allowed =3D true; =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* Vlan stripping setting */ if (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_VLAN) { if (dev_conf->rxmode.offloads & DEV_RX_OFFLOAD_VLAN_STRIP) @@ -522,7 +52= 5,8 @@ iavf_dev_info_get(struct rte_eth_dev *dev, struct rte_eth_dev_info *= dev_info) DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_JUMBO_FRAME | - DEV_RX_OFFLOAD_VLAN_FILTER; + DEV_RX_OFFLOAD_VLAN_FILTER | + DEV_RX_OFFLOAD_RSS_HASH; dev_info->tx_offload_capa =3D DEV_TX_OFFLOAD_VLAN_INSERT | DEV_TX_OFFLOAD_QINQ_INSERT | diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c in= dex d74675842..8ff96a96e 100644 --- a/drivers/net/ice/ice_ethdev.c +++ b/drivers/net/ice/ice_ethdev.c @@ -2357,6 +2357,9 @@ ice_dev_configure(struct rte_eth_dev *dev) ad->rx_bulk_alloc_allowed =3D true; ad->tx_simple_allowed =3D true; =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + return 0; } =20 @@ -2800,7 +2803,8 @@ ice_dev_info_get(struct rte_eth_dev *dev, struct rte_= eth_dev_info *dev_info) DEV_RX_OFFLOAD_TCP_CKSUM | DEV_RX_OFFLOAD_QINQ_STRIP | DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | - DEV_RX_OFFLOAD_VLAN_EXTEND; + DEV_RX_OFFLOAD_VLAN_EXTEND | + DEV_RX_OFFLOAD_RSS_HASH; dev_info->tx_offload_capa |=3D DEV_TX_OFFLOAD_QINQ_INSERT | DEV_TX_OFFLOAD_IPV4_CKSUM | diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_eth= dev.c index dbce7a80e..a299c1c74 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c @@ -2402,6 +2402,10 @@ ixgbe_dev_configure(struct rte_eth_dev *dev) int ret; =20 PMD_INIT_FUNC_TRACE(); + + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* multipe queue mode checking */ ret =3D ixgbe_check_mq_mode(dev); if (ret !=3D 0) { @@ -5140,6 +5144,9 @@ ixgbevf_dev_configure(struct rte_eth_dev *dev) PMD_INIT_LOG(DEBUG, "Configured Virtual Function port id: %d", dev->data->port_id); =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* * VF has no ability to enable/disable HW CRC * Keep the persistent behavior the same as Host PF diff --git a/drivers/= net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c index edcfa60ce..fa= 572d184 100644 --- a/drivers/net/ixgbe/ixgbe_rxtx.c +++ b/drivers/net/ixgbe/ixgbe_rxtx.c @@ -2872,7 +2872,8 @@ ixgbe_get_rx_port_offloads(struct rte_eth_dev *dev) DEV_RX_OFFLOAD_KEEP_CRC | DEV_RX_OFFLOAD_JUMBO_FRAME | DEV_RX_OFFLOAD_VLAN_FILTER | - DEV_RX_OFFLOAD_SCATTER; + DEV_RX_OFFLOAD_SCATTER | + DEV_RX_OFFLOAD_RSS_HASH; =20 if (hw->mac.type =3D=3D ixgbe_mac_82598EB) offloads |=3D DEV_RX_OFFLOAD_VLAN_STRIP; diff --git a/drivers/net/liquid= io/lio_ethdev.c b/drivers/net/liquidio/lio_ethdev.c index ec01343f1..d873b6ff4 100644 --- a/drivers/net/liquidio/lio_ethdev.c +++ b/drivers/net/liquidio/lio_ethdev.c @@ -412,7 +412,8 @@ lio_dev_info_get(struct rte_eth_dev *eth_dev, devinfo->rx_offload_capa =3D (DEV_RX_OFFLOAD_IPV4_CKSUM | DEV_RX_OFFLOAD_UDP_CKSUM | DEV_RX_OFFLOAD_TCP_CKSUM | - DEV_RX_OFFLOAD_VLAN_STRIP); + DEV_RX_OFFLOAD_VLAN_STRIP | + DEV_RX_OFFLOAD_RSS_HASH); devinfo->tx_offload_capa =3D (DEV_TX_OFFLOAD_IPV4_CKSUM | DEV_TX_OFFLOAD_UDP_CKSUM | DEV_TX_OFFLOAD_TCP_CKSUM | @@ -1735,6 +1736,10 @@ lio_dev_configure(struct rte_eth_dev *eth_dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(eth_dev->data->dev_conf.rxmode.offloads & + DEV_RX_OFFLOAD_RSS_HASH)) + eth_dev->data->dev_conf.rxmode.offloads |=3D + DEV_RX_OFFLOAD_RSS_HASH; /* Inform firmware about change in number of queues to use. * Disable IO queues and reset registers for re-configuration. */ diff --git a/drivers/net/mlx4/mlx4.c b/drivers/net/mlx4/mlx4.c index 931e4f= 4fe..6df2f6f90 100644 --- a/drivers/net/mlx4/mlx4.c +++ b/drivers/net/mlx4/mlx4.c @@ -248,6 +248,9 @@ mlx4_dev_configure(struct rte_eth_dev *dev) struct rte_flow_error error; int ret; =20 + if (!(dev->data->dev_conf.rxmode.offload & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offload |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* Prepare internal flow rules. */ ret =3D mlx4_flow_sync(priv, &error); if (ret) { diff --git a/drivers/net/mlx4/mlx4_rxq.c b/drivers/net/mlx4/mlx4_rxq.c inde= x f45c1ff85..4a6fbd922 100644 --- a/drivers/net/mlx4/mlx4_rxq.c +++ b/drivers/net/mlx4/mlx4_rxq.c @@ -685,7 +685,8 @@ mlx4_get_rx_queue_offloads(struct mlx4_priv *priv) { uint64_t offloads =3D DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_KEEP_CRC | - DEV_RX_OFFLOAD_JUMBO_FRAME; + DEV_RX_OFFLOAD_JUMBO_FRAME | + DEV_RX_OFFLOAD_RSS_HASH; =20 if (priv->hw_csum) offloads |=3D DEV_RX_OFFLOAD_CHECKSUM; diff --git a/drivers/net/mlx5/mlx5_ethdev.c b/drivers/net/mlx5/mlx5_ethdev.= c index 2278b24c0..e87d52ea1 100644 --- a/drivers/net/mlx5/mlx5_ethdev.c +++ b/drivers/net/mlx5/mlx5_ethdev.c @@ -407,6 +407,10 @@ mlx5_dev_configure(struct rte_eth_dev *dev) rte_errno =3D ENOMEM; return -rte_errno; } + + if (!(dev->data->dev_conf.rxmode.offload & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offload |=3D DEV_RX_OFFLOAD_RSS_HASH; + memcpy(priv->rss_conf.rss_key, use_app_rss_key ? dev->data->dev_conf.rx_adv_conf.rss_conf.rss_key : diff --git a/drivers/net/mlx5/mlx5_rxq.c b/drivers/net/mlx5/mlx5_rxq.c inde= x f0ab8438d..c8e1fc4b6 100644 --- a/drivers/net/mlx5/mlx5_rxq.c +++ b/drivers/net/mlx5/mlx5_rxq.c @@ -368,7 +368,8 @@ mlx5_get_rx_queue_offloads(struct rte_eth_dev *dev) struct mlx5_dev_config *config =3D &priv->config; uint64_t offloads =3D (DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_TIMESTAMP | - DEV_RX_OFFLOAD_JUMBO_FRAME); + DEV_RX_OFFLOAD_JUMBO_FRAME | + DEV_RX_OFFLOAD_RSS_HASH); =20 if (config->hw_fcs_strip) offloads |=3D DEV_RX_OFFLOAD_KEEP_CRC; diff --git a/drivers/net/netvsc/hn_ethdev.c b/drivers/net/netvsc/hn_ethdev.= c index eed8dece9..5c027e1a4 100644 --- a/drivers/net/netvsc/hn_ethdev.c +++ b/drivers/net/netvsc/hn_ethdev.c @@ -532,6 +532,9 @@ static int hn_dev_configure(struct rte_eth_dev *dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(rxmode->offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev_conf->rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + unsupported =3D txmode->offloads & ~HN_TX_OFFLOAD_CAPS; if (unsupported) { PMD_DRV_LOG(NOTICE, diff --git a/drivers/net/netvsc/hn_rndis.c b/drivers/net/netvsc/hn_rndis.c = index a67bc7a79..2b4714042 100644 --- a/drivers/net/netvsc/hn_rndis.c +++ b/drivers/net/netvsc/hn_rndis.c @@ -897,7 +897,8 @@ int hn_rndis_get_offload(struct hn_data *hv, =3D=3D HN_NDIS_LSOV2_CAP_IP6) dev_info->tx_offload_capa |=3D DEV_TX_OFFLOAD_TCP_TSO; =20 - dev_info->rx_offload_capa =3D DEV_RX_OFFLOAD_VLAN_STRIP; + dev_info->rx_offload_capa =3D DEV_RX_OFFLOAD_VLAN_STRIP | + DEV_RX_OFFLOAD_RSS_HASH; =20 if (hwcaps.ndis_csum.ndis_ip4_rxcsum & NDIS_RXCSUM_CAP_IP4) dev_info->rx_offload_capa |=3D DEV_RX_OFFLOAD_IPV4_CKSUM; diff --git a/d= rivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c index 22a8b2d19..e288a= 7f7e 100644 --- a/drivers/net/nfp/nfp_net.c +++ b/drivers/net/nfp/nfp_net.c @@ -407,6 +407,9 @@ nfp_net_configure(struct rte_eth_dev *dev) rxmode =3D &dev_conf->rxmode; txmode =3D &dev_conf->txmode; =20 + if (!(rxmode->offloads & DEV_RX_OFFLOAD_RSS_HASH)) + rxmode->offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* Checking TX mode */ if (txmode->mq_mode) { PMD_INIT_LOG(INFO, "TX mq_mode DCB and VMDq not supported"); @@ -1236,7 = +1239,8 @@ nfp_net_infos_get(struct rte_eth_dev *dev, struct rte_eth_dev_in= fo *dev_info) DEV_RX_OFFLOAD_UDP_CKSUM | DEV_RX_OFFLOAD_TCP_CKSUM; =20 - dev_info->rx_offload_capa |=3D DEV_RX_OFFLOAD_JUMBO_FRAME; + dev_info->rx_offload_capa |=3D DEV_RX_OFFLOAD_JUMBO_FRAME | + DEV_RX_OFFLOAD_RSS_HASH; =20 if (hw->cap & NFP_NET_CFG_CTRL_TXVLAN) dev_info->tx_offload_capa =3D DEV_TX_OFFLOAD_VLAN_INSERT; diff --git a/d= rivers/net/octeontx2/otx2_ethdev.c b/drivers/net/octeontx2/otx2_ethdev.c index 62291c698..d6e8ae745 100644 --- a/drivers/net/octeontx2/otx2_ethdev.c +++ b/drivers/net/octeontx2/otx2_ethdev.c @@ -575,7 +575,8 @@ nix_rx_offload_flags(struct rte_eth_dev *eth_dev) struct rte_eth_rxmode *rxmode =3D &conf->rxmode; uint16_t flags =3D 0; =20 - if (rxmode->mq_mode =3D=3D ETH_MQ_RX_RSS) + if (rxmode->mq_mode =3D=3D ETH_MQ_RX_RSS && + (dev->rx_offloads & DEV_RX_OFFLOAD_RSS_HASH)) flags |=3D NIX_RX_OFFLOAD_RSS_F; =20 if (dev->rx_offloads & (DEV_RX_OFFLOAD_TCP_CKSUM | diff --git a/drivers/n= et/octeontx2/otx2_ethdev.h b/drivers/net/octeontx2/otx2_ethdev.h index 4d9ed4870..d581240fe 100644 --- a/drivers/net/octeontx2/otx2_ethdev.h +++ b/drivers/net/octeontx2/otx2_ethdev.h @@ -122,8 +122,8 @@ DEV_TX_OFFLOAD_MT_LOCKFREE | \ DEV_TX_OFFLOAD_VLAN_INSERT | \ DEV_TX_OFFLOAD_QINQ_INSERT | \ - DEV_TX_OFFLOAD_OUTER_IPV4_CKSUM | \ - DEV_TX_OFFLOAD_OUTER_UDP_CKSUM | \ + DEV_TX_OFFLOAD_OUTER_IPV4_CKSUM | \ + DEV_TX_OFFLOAD_OUTER_UDP_CKSUM | \ DEV_TX_OFFLOAD_TCP_CKSUM | \ DEV_TX_OFFLOAD_UDP_CKSUM | \ DEV_TX_OFFLOAD_SCTP_CKSUM | \ @@ -140,11 +140,12 @@ DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | \ DEV_RX_OFFLOAD_SCATTER | \ DEV_RX_OFFLOAD_JUMBO_FRAME | \ - DEV_RX_OFFLOAD_OUTER_UDP_CKSUM | \ - DEV_RX_OFFLOAD_VLAN_STRIP | \ - DEV_RX_OFFLOAD_VLAN_FILTER | \ - DEV_RX_OFFLOAD_QINQ_STRIP | \ - DEV_RX_OFFLOAD_TIMESTAMP) + DEV_RX_OFFLOAD_OUTER_UDP_CKSUM | \ + DEV_RX_OFFLOAD_VLAN_STRIP | \ + DEV_RX_OFFLOAD_VLAN_FILTER | \ + DEV_RX_OFFLOAD_QINQ_STRIP | \ + DEV_RX_OFFLOAD_TIMESTAMP | \ + DEV_RX_OFFLOAD_RSS_HASH) =20 #define NIX_DEFAULT_RSS_CTX_GROUP 0 #define NIX_DEFAULT_RSS_MCAM_IDX -1 diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.= c index 53fdfde9a..8cdf04eaf 100644 --- a/drivers/net/qede/qede_ethdev.c +++ b/drivers/net/qede/qede_ethdev.c @@ -1182,6 +1182,9 @@ static int qede_dev_configure(struct rte_eth_dev *eth= _dev) =20 PMD_INIT_FUNC_TRACE(edev); =20 + if (!(rxmode->offloads & DEV_RX_OFFLOAD_RSS_HASH)) + rxmode->offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + /* We need to have min 1 RX queue.There is no min check in * rte_eth_dev_configure(), so we are checking it here. */ @@ -1302,7 +1305,8 @@ qede_dev_info_get(struct rte_eth_dev *eth_dev, DEV_RX_OFFLOAD_SCATTER | DEV_RX_OFFLOAD_JUMBO_FRAME | DEV_RX_OFFLOAD_VLAN_FILTER | - DEV_RX_OFFLOAD_VLAN_STRIP); + DEV_RX_OFFLOAD_VLAN_STRIP | + DEV_RX_OFFLOAD_RSS_HASH); dev_info->rx_queue_offload_capa =3D 0; =20 /* TX offloads are on a per-packet basis, so it is applicable diff --git = a/drivers/net/sfc/sfc_ef10_essb_rx.c b/drivers/net/sfc/sfc_ef10_essb_rx.c index 63da807ea..d9d2ce6bd 100644 --- a/drivers/net/sfc/sfc_ef10_essb_rx.c +++ b/drivers/net/sfc/sfc_ef10_essb_rx.c @@ -715,7 +715,8 @@ struct sfc_dp_rx sfc_ef10_essb_rx =3D { }, .features =3D SFC_DP_RX_FEAT_FLOW_FLAG | SFC_DP_RX_FEAT_FLOW_MARK, - .dev_offload_capa =3D DEV_RX_OFFLOAD_CHECKSUM, + .dev_offload_capa =3D DEV_RX_OFFLOAD_CHECKSUM | + DEV_RX_OFFLOAD_RSS_HASH, .queue_offload_capa =3D 0, .get_dev_info =3D sfc_ef10_essb_rx_get_dev_info, .pool_ops_supported =3D sfc_ef10_essb_rx_pool_ops_supported, diff --git a/drivers/net/sfc/sfc_ef10_rx.c b/drivers/net/sfc/sfc_ef10_rx.c = index f2fc6e70a..9e527b7fb 100644 --- a/drivers/net/sfc/sfc_ef10_rx.c +++ b/drivers/net/sfc/sfc_ef10_rx.c @@ -796,7 +796,8 @@ struct sfc_dp_rx sfc_ef10_rx =3D { .features =3D SFC_DP_RX_FEAT_MULTI_PROCESS | SFC_DP_RX_FEAT_INTR, .dev_offload_capa =3D DEV_RX_OFFLOAD_CHECKSUM | - DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM, + DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM | + DEV_RX_OFFLOAD_RSS_HASH, .queue_offload_capa =3D DEV_RX_OFFLOAD_SCATTER, .get_dev_info =3D sfc_ef10_rx_get_dev_info, .qsize_up_rings =3D sfc_ef10_rx_qsize_up_rings, diff --git a/drivers/net/sfc/sfc_rx.c b/drivers/net/sfc/sfc_rx.c index e680= 9bb64..10fa1e5ff 100644 --- a/drivers/net/sfc/sfc_rx.c +++ b/drivers/net/sfc/sfc_rx.c @@ -617,7 +617,8 @@ struct sfc_dp_rx sfc_efx_rx =3D { .hw_fw_caps =3D 0, }, .features =3D SFC_DP_RX_FEAT_INTR, - .dev_offload_capa =3D DEV_RX_OFFLOAD_CHECKSUM, + .dev_offload_capa =3D DEV_RX_OFFLOAD_CHECKSUM | + DEV_RX_OFFLOAD_RSS_HASH, .queue_offload_capa =3D DEV_RX_OFFLOAD_SCATTER, .qsize_up_rings =3D sfc_efx_rx_qsize_up_rings, .qcreate =3D sfc_efx_rx_qcreate, @@ -1556,6 +1557,10 @@ sfc_rx_check_mode(struct sfc_adapter *sa, struct rte= _eth_rxmode *rxmode) rxmode->offloads |=3D DEV_RX_OFFLOAD_OUTER_IPV4_CKSUM; } =20 + if ((offloads_supported & DEV_RX_OFFLOAD_RSS_HASH) && + (~rxmode->offloads & DEV_RX_OFFLOAD_RSS_HASH)) + rxmode->offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + return rc; } =20 diff --git a/drivers/net/thunderx/nicvf_ethdev.c b/drivers/net/thunderx/nic= vf_ethdev.c index b93d45712..28ee3e46d 100644 --- a/drivers/net/thunderx/nicvf_ethdev.c +++ b/drivers/net/thunderx/nicvf_ethdev.c @@ -1920,6 +1920,9 @@ nicvf_dev_configure(struct rte_eth_dev *dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(rxmode->offloads & DEV_RX_OFFLOAD_RSS_HASH)) + rxmode->offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + if (!rte_eal_has_hugepages()) { PMD_INIT_LOG(INFO, "Huge page is not configured"); return -EINVAL; diff --git a/drivers/net/thunderx/nicvf_ethdev.h b/drivers/net/thunderx/nic= vf_ethdev.h index c0bfbf848..391411799 100644 --- a/drivers/net/thunderx/nicvf_ethdev.h +++ b/drivers/net/thunderx/nicvf_ethdev.h @@ -41,7 +41,8 @@ DEV_RX_OFFLOAD_CHECKSUM | \ DEV_RX_OFFLOAD_VLAN_STRIP | \ DEV_RX_OFFLOAD_JUMBO_FRAME | \ - DEV_RX_OFFLOAD_SCATTER) + DEV_RX_OFFLOAD_SCATTER | \ + DEV_RX_OFFLOAD_RSS_HASH) =20 #define NICVF_DEFAULT_RX_FREE_THRESH 224 #define NICVF_DEFAULT_TX_FREE_THRESH 224 diff --git a/drivers/net/vmxnet3/vmxnet3_ethdev.c b/drivers/net/vmxnet3/vmx= net3_ethdev.c index d1faeaa81..5ef6ad43c 100644 --- a/drivers/net/vmxnet3/vmxnet3_ethdev.c +++ b/drivers/net/vmxnet3/vmxnet3_ethdev.c @@ -56,7 +56,8 @@ DEV_RX_OFFLOAD_UDP_CKSUM | \ DEV_RX_OFFLOAD_TCP_CKSUM | \ DEV_RX_OFFLOAD_TCP_LRO | \ - DEV_RX_OFFLOAD_JUMBO_FRAME) + DEV_RX_OFFLOAD_JUMBO_FRAME | \ + DEV_RX_OFFLOAD_RSS_HASH) =20 static int eth_vmxnet3_dev_init(struct rte_eth_dev *eth_dev); static int = eth_vmxnet3_dev_uninit(struct rte_eth_dev *eth_dev); @@ -407,6 +408,9 @@ vm= xnet3_dev_configure(struct rte_eth_dev *dev) =20 PMD_INIT_FUNC_TRACE(); =20 + if (!(dev->data->dev_conf.rxmode.offloads & DEV_RX_OFFLOAD_RSS_HASH)) + dev->data->dev_conf.rxmode.offloads |=3D DEV_RX_OFFLOAD_RSS_HASH; + if (dev->data->nb_tx_queues > VMXNET3_MAX_TX_QUEUES || dev->data->nb_rx_queues > VMXNET3_MAX_RX_QUEUES) { PMD_INIT_LOG(ERR, "ERROR: Number of queues not supported"); -- 2.17.1