[dpdk-stable] patch 'net/iavf: fix RSS RETA after restart' has been queued to stable release 19.11.4
luca.boccassi at gmail.com
luca.boccassi at gmail.com
Fri Jul 24 13:59:06 CEST 2020
Hi,
FYI, your patch has been queued to stable release 19.11.4
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 07/26/20. 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.
Thanks.
Luca Boccassi
---
>From 80b3bfdd5adeb4a8f2f1dcfed8760d22e762ca7d Mon Sep 17 00:00:00 2001
From: Junyu Jiang <junyux.jiang at intel.com>
Date: Fri, 19 Jun 2020 07:44:02 +0000
Subject: [PATCH] net/iavf: fix RSS RETA after restart
[ upstream commit 1feb8e3f4e5c69071e5c461132a8b1bad05609af ]
This patch moved the RSS initialization from dev start to
dev configure, to fix the issue that RSS redirection table
can not be kept after restarting port.
Fixes: 69dd4c3d0898 ("net/avf: enable queue and device")
Signed-off-by: Junyu Jiang <junyux.jiang at intel.com>
Acked-by: Qiming Yang <qiming.yang at intel.com>
---
drivers/net/iavf/iavf_ethdev.c | 71 +++++++++++++++++-----------------
1 file changed, 35 insertions(+), 36 deletions(-)
diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
index 3f41eefff..8ddd4aad9 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
@@ -132,34 +132,6 @@ static const struct eth_dev_ops iavf_eth_dev_ops = {
.rx_queue_intr_disable = iavf_dev_rx_queue_intr_disable,
};
-static int
-iavf_dev_configure(struct rte_eth_dev *dev)
-{
- struct iavf_adapter *ad =
- IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
- struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(ad);
- struct rte_eth_conf *dev_conf = &dev->data->dev_conf;
-
- ad->rx_bulk_alloc_allowed = true;
- /* Initialize to TRUE. If any of Rx queues doesn't meet the
- * vector Rx/Tx preconditions, it will be reset.
- */
- ad->rx_vec_allowed = true;
- ad->tx_vec_allowed = true;
-
- if (dev->data->dev_conf.rxmode.mq_mode & ETH_MQ_RX_RSS_FLAG)
- dev->data->dev_conf.rxmode.offloads |= 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)
- iavf_enable_vlan_strip(ad);
- else
- iavf_disable_vlan_strip(ad);
- }
- return 0;
-}
-
static int
iavf_init_rss(struct iavf_adapter *adapter)
{
@@ -216,6 +188,41 @@ iavf_init_rss(struct iavf_adapter *adapter)
return 0;
}
+static int
+iavf_dev_configure(struct rte_eth_dev *dev)
+{
+ struct iavf_adapter *ad =
+ IAVF_DEV_PRIVATE_TO_ADAPTER(dev->data->dev_private);
+ struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(ad);
+ struct rte_eth_conf *dev_conf = &dev->data->dev_conf;
+
+ ad->rx_bulk_alloc_allowed = true;
+ /* Initialize to TRUE. If any of Rx queues doesn't meet the
+ * vector Rx/Tx preconditions, it will be reset.
+ */
+ ad->rx_vec_allowed = true;
+ ad->tx_vec_allowed = true;
+
+ if (dev->data->dev_conf.rxmode.mq_mode & ETH_MQ_RX_RSS_FLAG)
+ dev->data->dev_conf.rxmode.offloads |= 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)
+ iavf_enable_vlan_strip(ad);
+ else
+ iavf_disable_vlan_strip(ad);
+ }
+
+ if (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_RSS_PF) {
+ if (iavf_init_rss(ad) != 0) {
+ PMD_DRV_LOG(ERR, "configure rss failed");
+ return -1;
+ }
+ }
+ return 0;
+}
+
static int
iavf_init_rxq(struct rte_eth_dev *dev, struct iavf_rx_queue *rxq)
{
@@ -436,13 +443,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
return -1;
}
- if (vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_RSS_PF) {
- if (iavf_init_rss(adapter) != 0) {
- PMD_DRV_LOG(ERR, "configure rss failed");
- goto err_rss;
- }
- }
-
if (iavf_configure_queues(adapter) != 0) {
PMD_DRV_LOG(ERR, "configure queues failed");
goto err_queue;
@@ -471,7 +471,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
err_mac:
iavf_add_del_all_mac_addr(adapter, FALSE);
err_queue:
-err_rss:
return -1;
}
--
2.20.1
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2020-07-24 12:53:52.704650483 +0100
+++ 0108-net-iavf-fix-RSS-RETA-after-restart.patch 2020-07-24 12:53:48.359007801 +0100
@@ -1,14 +1,15 @@
-From 1feb8e3f4e5c69071e5c461132a8b1bad05609af Mon Sep 17 00:00:00 2001
+From 80b3bfdd5adeb4a8f2f1dcfed8760d22e762ca7d Mon Sep 17 00:00:00 2001
From: Junyu Jiang <junyux.jiang at intel.com>
Date: Fri, 19 Jun 2020 07:44:02 +0000
Subject: [PATCH] net/iavf: fix RSS RETA after restart
+[ upstream commit 1feb8e3f4e5c69071e5c461132a8b1bad05609af ]
+
This patch moved the RSS initialization from dev start to
dev configure, to fix the issue that RSS redirection table
can not be kept after restarting port.
Fixes: 69dd4c3d0898 ("net/avf: enable queue and device")
-Cc: stable at dpdk.org
Signed-off-by: Junyu Jiang <junyux.jiang at intel.com>
Acked-by: Qiming Yang <qiming.yang at intel.com>
@@ -17,11 +18,11 @@
1 file changed, 35 insertions(+), 36 deletions(-)
diff --git a/drivers/net/iavf/iavf_ethdev.c b/drivers/net/iavf/iavf_ethdev.c
-index b0dd49a8d..c3aa4cd72 100644
+index 3f41eefff..8ddd4aad9 100644
--- a/drivers/net/iavf/iavf_ethdev.c
+++ b/drivers/net/iavf/iavf_ethdev.c
-@@ -122,34 +122,6 @@ static const struct eth_dev_ops iavf_eth_dev_ops = {
- .filter_ctrl = iavf_dev_filter_ctrl,
+@@ -132,34 +132,6 @@ static const struct eth_dev_ops iavf_eth_dev_ops = {
+ .rx_queue_intr_disable = iavf_dev_rx_queue_intr_disable,
};
-static int
@@ -55,7 +56,7 @@
static int
iavf_init_rss(struct iavf_adapter *adapter)
{
-@@ -206,6 +178,41 @@ iavf_init_rss(struct iavf_adapter *adapter)
+@@ -216,6 +188,41 @@ iavf_init_rss(struct iavf_adapter *adapter)
return 0;
}
@@ -97,7 +98,7 @@
static int
iavf_init_rxq(struct rte_eth_dev *dev, struct iavf_rx_queue *rxq)
{
-@@ -426,13 +433,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
+@@ -436,13 +443,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
return -1;
}
@@ -111,9 +112,9 @@
if (iavf_configure_queues(adapter) != 0) {
PMD_DRV_LOG(ERR, "configure queues failed");
goto err_queue;
-@@ -461,7 +461,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
+@@ -471,7 +471,6 @@ iavf_dev_start(struct rte_eth_dev *dev)
err_mac:
- iavf_add_del_all_mac_addr(adapter, false);
+ iavf_add_del_all_mac_addr(adapter, FALSE);
err_queue:
-err_rss:
return -1;
More information about the stable
mailing list