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 D3FD1A0093; Sat, 24 Dec 2022 11:02:12 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 73B58410FB; Sat, 24 Dec 2022 11:02:12 +0100 (CET) Received: from CY4PR02CU007-vft-obe.outbound.protection.outlook.com (mail-westcentralusazon11011012.outbound.protection.outlook.com [40.93.199.12]) by mails.dpdk.org (Postfix) with ESMTP id 6AFA2400D7 for ; Thu, 22 Dec 2022 09:24:45 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Tw07kMnre8Q6MyGrYR7kjqfInKRg741V1I1TeHV8Tn/B7n1lMYZwBJVTAXQ1+kiVLjezFFNT/24ubee9o8KmDHgpwiMN75ay9Z2sag3xTBUuCVEu3TwI3/ChzS5l2nnS35CyOoLuiLkrRee5TQlt4Fw7q9C5dObUUkmo/lw/cjKx1iNPvV+CUSwu6NHNZN0YXwDNGcz+4C8nXSksjnq/Om7VprsH5fLBLtvDxeKl+h0NGOOZzkr7C840/b3Goq6gfWGbIvVGvSsHzIgxNdopyaxNSfdNrVzsAUQGv/P+vMwxUUVccVbBY2IKlm4iTykz4lnS/T32uNnCb8zl0DLxLg== 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=H/FCPbXXK0UVu2sje9RYGP3FJXfBNZRaiJvfEmlrOdA=; b=iHRyds7GgKiSZ7mp5NPHjRAcrTfHITcdlUgGW+uJv1z5SqlksGJECn+yvCrIEk+XcOf0fHZDJ5YRwydoxOMimTHfRlkLVD4ezYbyckNFtQr0wmHIy0BdMVZcDbmqfZIG/bNHPJqbwIaN0MyX3FwTmv6xJ9iOr1zPhgGuZpbWCTQqRcrHhs/Yn8kLXHSuM2LnVem5X/1U5YVo29MVuAGLf25phkeH63IsHA/VW0u6Cxoz7zhtHqPDK9IsD/Hql0rrbKZDE1SmLUqiwGu3awTZxntUNfkt9+VmUstS/2Gq/3KB7zhV5BEyWF4HvsYJ7YonD8kgUQhz7bvCRcpAVBtAhA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vmware.com; dmarc=pass action=none header.from=vmware.com; dkim=pass header.d=vmware.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vmware.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=H/FCPbXXK0UVu2sje9RYGP3FJXfBNZRaiJvfEmlrOdA=; b=k+gKHGEIEFl8HwzfNUQYXHvgMKHYE/t08Xtrf7BXYC94+GadFxwar6fwwiXD3iYJ18jWmZ2pr2hni67KBtpJtE7BAF/BAAFypbeiOuMUG2Adbq1OzU8pE9EsShMh9GBa3Qolu4REk8LcYyn+5ikVhf2vtyNn38oOMj28UBU+PFg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vmware.com; Received: from SA1PR05MB8390.namprd05.prod.outlook.com (2603:10b6:806:1d5::8) by IA0PR05MB9563.namprd05.prod.outlook.com (2603:10b6:208:434::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5924.16; Thu, 22 Dec 2022 08:24:43 +0000 Received: from SA1PR05MB8390.namprd05.prod.outlook.com ([fe80::7c4e:648d:4b39:ce84]) by SA1PR05MB8390.namprd05.prod.outlook.com ([fe80::7c4e:648d:4b39:ce84%3]) with mapi id 15.20.5924.022; Thu, 22 Dec 2022 08:24:43 +0000 From: Raghav Roy To: dev@dpdk.org Cc: jbehrens@vmware.com Subject: [PATCH] net/vmxnet3: added checks for TCP for RSS Configuration Date: Thu, 22 Dec 2022 00:24:34 -0800 Message-Id: <20221222082434.18336-1-royra@vmware.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20221221041917.29569-1-royra@vmware.com> References: <20221221041917.29569-1-royra@vmware.com> Content-Type: text/plain X-ClientProxiedBy: BYAPR11CA0057.namprd11.prod.outlook.com (2603:10b6:a03:80::34) To SA1PR05MB8390.namprd05.prod.outlook.com (2603:10b6:806:1d5::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SA1PR05MB8390:EE_|IA0PR05MB9563:EE_ X-MS-Office365-Filtering-Correlation-Id: 569330a0-fec6-4080-397e-08dae3f5fa33 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: aH18od2uCSay4R84Z34ibwWn3T/VRERXimuEEyk1P3ew2DOn/eJ0+wNqeGjdnBsf2MY32XAJfyy4JuaJoelNkGjaPCTIwIvjqiFMsVVsIcuOrqqH//Pc+R91JEhyAsZVqmL+85R7kekri/sUKJvWNkiVduPkQ+JlXCkQfvFPrkyDqcLs4DShpJOmcs6yxAPaJcUNf2D8JLNkeO81H6BF0XXjv/J+fTUUtU0uWdoEeo4PTVZxXbMguwvCaTZDegw1MfM9p5qOMGw74yNVf32Fl5tllBHu1EUJrrwPoR9p/OKmoyAsaX6/syqGecKCocctGOmerD1IQWE/CPRtC+o3M0f21qWdxxs2gbLc5AKPvtK+CQyF3jwwPTrNHjP1RTmZzqV/+4mWa7RnwC+jHpB2miTj+lu31afBYRFITXRLvlQnnOUAURNx+O0KhQ+HaK5A3E+G5kj9MVaQRCeun6zlm2LoAuJmtukOrxT9DgEZInXDNpdMvJK4Y9noGJjoEepJsLXPFwVhd0/jfW+TJIwz5tVhF0EqVWQzfH25bEV3AN65dpEqmmrJ0VIqQDMnNPyoA4bIYDb92kfhpY1sKJQ5u7KNFHyNorqHUAkxpuFYJL8tK5WWhFE1fr3v6QhirJJ/niipglvGnvzGwEmOPiZG7dbO2k03lpndww/D6p7qv9Uw4bdhBgJKlfbORO0XC55yeigdk0zPW38ZmEXUOaW5fg== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SA1PR05MB8390.namprd05.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230022)(4636009)(346002)(136003)(39860400002)(376002)(366004)(396003)(451199015)(6916009)(6506007)(316002)(6486002)(478600001)(38100700002)(38350700002)(8676002)(4326008)(52116002)(2616005)(86362001)(66476007)(1076003)(36756003)(66946007)(66556008)(83380400001)(5660300002)(8936002)(107886003)(6666004)(2906002)(26005)(41300700001)(186003)(6512007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?ZN9W0vop+KfQveW8sIcvkhUqYMBle9YMEkIjnexDTwERlEOhur44rvYm3F7h?= =?us-ascii?Q?JTXxlAZn7q6LNzI+9U7AuckIugcCtErE9YBvM5uA7bbpQT9qafBhZiSwjCk9?= =?us-ascii?Q?2TXxBgHtaHrU8Sr/Z6kR/EhAgkYqtU6w3lVHgp5YQWGbcZDEQ5b8kOk6ROcL?= =?us-ascii?Q?SBUma3O40WZfFO6r96ECpRNUYwthSm5/4tsF0vc1HbZQ3zabhh0TsTv/fK7i?= =?us-ascii?Q?VQR6dEQlLKWfgjQQua5GSlTNQe4QTZPAKzv/JtYTKO6jIQzmz3StW2nVUWqV?= =?us-ascii?Q?vxardk4Rjn3HXEANPH6gsr1OFDa8V0uCELTk+n7X64B9Q/J30UpkyWV/bHni?= =?us-ascii?Q?etzAseazWcyUvNbaWRVpXcw+t8EoCVjRVojoTsHOVp8ZDMLHMeXHyd40mzn1?= =?us-ascii?Q?1mTrjIiAQVGoQBFZHtuWtpe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RRSF7ntLt+63U9upGkJmgkQX+499cA6JslERFva3E5QC2hFxT9GcCSV4?= =?us-ascii?Q?CfyKPR4LevMkIp8PaLNtr57aaX3Hh7bVGnvtH7ToHcRVdPGhzPlAnA13pwQ9?= =?us-ascii?Q?rPp+TTYOwcc5ziNYkBOCcATHiyDeI2L7+2t0QOLrmcvAMw/UBaU5EUPM1/Bw?= =?us-ascii?Q?1v1bVj29clp9ItlwwCfQlx6QRPJrwbzbWYJlJmjmYBRb5HhiS+XD0oIvUQSJ?= =?us-ascii?Q?38iY11C+oY6YuFp4nJo=3D?= X-OriginatorOrg: vmware.com X-MS-Exchange-CrossTenant-Network-Message-Id: 569330a0-fec6-4080-397e-08dae3f5fa33 X-MS-Exchange-CrossTenant-AuthSource: SA1PR05MB8390.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Dec 2022 08:24:43.2374 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: b39138ca-3cee-4b4a-a4d6-cd83d9dd62f0 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: j4rE8Ohfr9nAiBwDykTfgSdZcsPTDYBt8JnAqJ1iqUiLwuOWAlJIOkUYRMcUrFSFV1ByjkJtwqNHlDuMLAXFcw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA0PR05MB9563 X-Mailman-Approved-At: Sat, 24 Dec 2022 11:02:11 +0100 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Added checks for TCP in vmxnet3_rss_configure() This check ensures the hashType for RSS, when enabled just for UDP, is not NONE. Signed-off-by: Raghav Roy --- drivers/net/vmxnet3/vmxnet3_rxtx.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/net/vmxnet3/vmxnet3_rxtx.c b/drivers/net/vmxnet3/vmxnet3_rxtx.c index a875ffec07..e8407c9b2e 100644 --- a/drivers/net/vmxnet3/vmxnet3_rxtx.c +++ b/drivers/net/vmxnet3/vmxnet3_rxtx.c @@ -1412,6 +1412,13 @@ vmxnet3_rss_configure(struct rte_eth_dev *dev) dev_rss_conf = hw->rss_conf; port_rss_conf = &dev->data->dev_conf.rx_adv_conf.rss_conf; + if ((port_rss_conf->rss_hf & VMXNET3_MANDATORY_V4_RSS) != + VMXNET3_MANDATORY_V4_RSS) { + PMD_INIT_LOG(WARNING, "RSS: IPv4/6 TCP is required for vmxnet3 RSS, " + "automatically setting it"); + port_rss_conf->rss_hf |= VMXNET3_MANDATORY_V4_RSS; + } + /* loading hashFunc */ dev_rss_conf->hashFunc = VMXNET3_RSS_HASH_FUNC_TOEPLITZ; /* loading hashKeySize */ @@ -1419,6 +1426,7 @@ vmxnet3_rss_configure(struct rte_eth_dev *dev) /* loading indTableSize: Must not exceed VMXNET3_RSS_MAX_IND_TABLE_SIZE (128)*/ dev_rss_conf->indTableSize = (uint16_t)((MAX_RX_QUEUES(hw)) * 4); + if (port_rss_conf->rss_key == NULL) { /* Default hash key */ port_rss_conf->rss_key = rss_intel_key; @@ -1446,6 +1454,5 @@ vmxnet3_rss_configure(struct rte_eth_dev *dev) dev_rss_conf->hashType |= VMXNET3_RSS_HASH_TYPE_IPV6; if (rss_hf & RTE_ETH_RSS_NONFRAG_IPV6_TCP) dev_rss_conf->hashType |= VMXNET3_RSS_HASH_TYPE_TCP_IPV6; - return VMXNET3_SUCCESS; } -- 2.17.1