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 70A2B41EA5 for ; Wed, 15 Mar 2023 23:47:07 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6BE9240EE4; Wed, 15 Mar 2023 23:47:07 +0100 (CET) Received: from mail-wr1-f54.google.com (mail-wr1-f54.google.com [209.85.221.54]) by mails.dpdk.org (Postfix) with ESMTP id B1ED240EE4 for ; Wed, 15 Mar 2023 23:47:05 +0100 (CET) Received: by mail-wr1-f54.google.com with SMTP id i9so9678191wrp.3 for ; Wed, 15 Mar 2023 15:47:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678920425; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LncOYgSizzNeVzZ7c7EHagdU+msSu+29CJnJ+z6a4Fs=; b=Js8qIlKOwcsVaMY3Xp3tyz75Q9E1mnhjlrlksbBcidqMazWEU5csrvoeRcykgH15/Z hWRPm2s9UftoEqEBCr6OL4EkppaglDykDREU/VU7ePHBVrvVoGVe5svU3W7R806aPl0M 3yjerf10VYwQNuJabEO/CQNzaMr5CdofgjVeF4dy6/CkyTP17HoXKpZnLNthAB230FBP SKQBwWrzGepNyEgsau2HaKm0HIDqBw9NIbWqfuaBCtu6NrckGppFgYWO56PrVmphZkQZ +gGgZKhhse17V3Ikg73TVp+kViqOV2uk7JuGRPGR3IclFrta2k9C8M+IXsB3/k7I0dPV QEPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678920425; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LncOYgSizzNeVzZ7c7EHagdU+msSu+29CJnJ+z6a4Fs=; b=yRnfeW/6liJUIqVqbiQUDUvB4eC2s79EtF9M1yDITtuh0CXhZ5hr8unBCN2S8MS9nC vrB6WYnclM9xLBaKK+7NBoTUDGst0A28qlGw7CwrgUvsIE4lJvgUtuSZMOlKuAAvx2hx jFU4ecEsDewZpzDXS4ejhoKFr88fzCCxMXO+k8VCRyrM30JZOL3dddivKRiwR/uMtW1D afx4bkQJ2gCoMVwsVZ2L39UtorCezUOBbi3H6NvdoELqujxgVFcTOA+144+ZnOF4rA9L DmcsNaGM9Cq4qeOCF4Chq3r6DFKGaAFGBg7IpfjPRF5G1Nk+Us+fPRQgli+45QK/ziZV WopA== X-Gm-Message-State: AO0yUKXioBJAZUMueg4h249edITmeYHYIbc6GMiA3dY+KzIwsO97y8DI YAfC9raCird5XpKS7m7N5Fd6906nT5dUyg== X-Google-Smtp-Source: AK7set9IOFlscg4P2CXLm5gcc+2JfOZgYSp2P7zNA0/l0oFcVDFyd7fp7CXoKwOhGQvESpLcpT8+eA== X-Received: by 2002:adf:f344:0:b0:2cf:e74f:2957 with SMTP id e4-20020adff344000000b002cfe74f2957mr2957061wrp.33.1678920425350; Wed, 15 Mar 2023 15:47:05 -0700 (PDT) Received: from localhost ([2a01:4b00:d307:1000:f1d3:eb5e:11f4:a7d9]) by smtp.gmail.com with ESMTPSA id z4-20020a5d6544000000b002c56013c07fsm5698046wrv.109.2023.03.15.15.47.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Mar 2023 15:47:05 -0700 (PDT) From: luca.boccassi@gmail.com To: Long Wu Cc: Chaoyong He , =?UTF-8?q?Niklas=20S=C3=B6derlund?= , dpdk stable Subject: patch 'net/nfp: fix getting RSS configuration' has been queued to stable release 20.11.8 Date: Wed, 15 Mar 2023 22:46:03 +0000 Message-Id: <20230315224631.1025649-12-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230315224631.1025649-1-luca.boccassi@gmail.com> References: <20230223093715.3926893-71-luca.boccassi@gmail.com> <20230315224631.1025649-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Hi, FYI, your patch has been queued to stable release 20.11.8 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 03/17/23. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/1c5ef4ee290c42fc4d394f3d4fda873194c97036 Thanks. Luca Boccassi --- >From 1c5ef4ee290c42fc4d394f3d4fda873194c97036 Mon Sep 17 00:00:00 2001 From: Long Wu Date: Tue, 21 Feb 2023 13:52:22 +0800 Subject: [PATCH] net/nfp: fix getting RSS configuration MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [ upstream commit ef26b8a08cd2ba0b47d3ca71316ea6e865abb6fd ] "NFP_NET_CFG_RSS_IPV4" and "NFP_NET_CFG_RSS_IPV6" represent that firmware will calculate RSS base on L3 rather than UDP or TCP information from packets. So the logic of return RSS configuration in driver is wrong. Modify code to return the right configuration. Fixes: 934e4c60fbff ("nfp: add RSS") Signed-off-by: Long Wu Reviewed-by: Chaoyong He Reviewed-by: Niklas Söderlund --- drivers/net/nfp/nfp_net.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c index f4925e1879..4957cc7eda 100644 --- a/drivers/net/nfp/nfp_net.c +++ b/drivers/net/nfp/nfp_net.c @@ -2652,7 +2652,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, cfg_rss_ctrl = nn_cfg_readl(hw, NFP_NET_CFG_RSS_CTRL); if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4) - rss_hf |= ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_NONFRAG_IPV4_UDP; + rss_hf |= ETH_RSS_IPV4; if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4_TCP) rss_hf |= ETH_RSS_NONFRAG_IPV4_TCP; @@ -2667,7 +2667,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, rss_hf |= ETH_RSS_NONFRAG_IPV6_UDP; if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV6) - rss_hf |= ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_NONFRAG_IPV6_UDP; + rss_hf |= ETH_RSS_IPV6; /* Propagate current RSS hash functions to caller */ rss_conf->rss_hf = rss_hf; -- 2.39.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-03-15 22:44:50.320472535 +0000 +++ 0012-net-nfp-fix-getting-RSS-configuration.patch 2023-03-15 22:44:49.531849171 +0000 @@ -1 +1 @@ -From ef26b8a08cd2ba0b47d3ca71316ea6e865abb6fd Mon Sep 17 00:00:00 2001 +From 1c5ef4ee290c42fc4d394f3d4fda873194c97036 Mon Sep 17 00:00:00 2001 @@ -8,0 +9,2 @@ +[ upstream commit ef26b8a08cd2ba0b47d3ca71316ea6e865abb6fd ] + @@ -17 +18,0 @@ -Cc: stable@dpdk.org @@ -23 +24 @@ - drivers/net/nfp/nfp_common.c | 4 ++-- + drivers/net/nfp/nfp_net.c | 4 ++-- @@ -26,5 +27,5 @@ -diff --git a/drivers/net/nfp/nfp_common.c b/drivers/net/nfp/nfp_common.c -index 837056cc12..5922bfea8e 100644 ---- a/drivers/net/nfp/nfp_common.c -+++ b/drivers/net/nfp/nfp_common.c -@@ -1420,7 +1420,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, +diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c +index f4925e1879..4957cc7eda 100644 +--- a/drivers/net/nfp/nfp_net.c ++++ b/drivers/net/nfp/nfp_net.c +@@ -2652,7 +2652,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, @@ -34,2 +35,2 @@ -- rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_TCP | RTE_ETH_RSS_NONFRAG_IPV4_UDP; -+ rss_hf |= RTE_ETH_RSS_IPV4; +- rss_hf |= ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_NONFRAG_IPV4_UDP; ++ rss_hf |= ETH_RSS_IPV4; @@ -38,3 +39,3 @@ - rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_TCP; -@@ -1435,7 +1435,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, - rss_hf |= RTE_ETH_RSS_NONFRAG_IPV6_UDP; + rss_hf |= ETH_RSS_NONFRAG_IPV4_TCP; +@@ -2667,7 +2667,7 @@ nfp_net_rss_hash_conf_get(struct rte_eth_dev *dev, + rss_hf |= ETH_RSS_NONFRAG_IPV6_UDP; @@ -43,2 +44,2 @@ -- rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_UDP | RTE_ETH_RSS_NONFRAG_IPV6_UDP; -+ rss_hf |= RTE_ETH_RSS_IPV6; +- rss_hf |= ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_NONFRAG_IPV6_UDP; ++ rss_hf |= ETH_RSS_IPV6; @@ -46,2 +47,2 @@ - if (cfg_rss_ctrl & NFP_NET_CFG_RSS_IPV4_SCTP) - rss_hf |= RTE_ETH_RSS_NONFRAG_IPV4_SCTP; + /* Propagate current RSS hash functions to caller */ + rss_conf->rss_hf = rss_hf;