[dpdk-stable] patch 'net/qede: fix multicast drop in promiscuous mode' has been queued to stable release 19.11.4

luca.boccassi at gmail.com luca.boccassi at gmail.com
Fri Jul 24 13:58:19 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 889b24bdd1573d9839df7ffebae1e04592cdd090 Mon Sep 17 00:00:00 2001
From: Devendra Singh Rawat <dsinghrawat at marvell.com>
Date: Thu, 18 Jun 2020 13:45:55 +0530
Subject: [PATCH] net/qede: fix multicast drop in promiscuous mode

[ upstream commit b10231aed1edb9cdd74a0a021a38267255952f00 ]

After enabling promiscuous mode all packets whose destination MAC
address is a multicast address were being dropped. This fix configures
H/W to receive all traffic in promiscuous mode. Promiscuous mode also
overrides allmulticast mode on/off status.

Fixes: 40e9f6fc1558 ("net/qede: enable VF-VF traffic with unmatched dest address")

Signed-off-by: Devendra Singh Rawat <dsinghrawat at marvell.com>
Signed-off-by: Igor Russkikh <irusskikh at marvell.com>
Signed-off-by: Rasesh Mody <rmody at marvell.com>
---
 drivers/net/qede/qede_ethdev.c | 25 +++++++++----------------
 1 file changed, 9 insertions(+), 16 deletions(-)

diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c
index 2a1c82ac9..abb82d336 100644
--- a/drivers/net/qede/qede_ethdev.c
+++ b/drivers/net/qede/qede_ethdev.c
@@ -551,17 +551,16 @@ qed_configure_filter_rx_mode(struct rte_eth_dev *eth_dev,
 		ECORE_ACCEPT_BCAST;
 
 	if (type == QED_FILTER_RX_MODE_TYPE_PROMISC) {
-		flags.rx_accept_filter |= ECORE_ACCEPT_UCAST_UNMATCHED;
+		flags.rx_accept_filter |= (ECORE_ACCEPT_UCAST_UNMATCHED |
+					   ECORE_ACCEPT_MCAST_UNMATCHED);
 		if (IS_VF(edev)) {
-			flags.tx_accept_filter |= ECORE_ACCEPT_UCAST_UNMATCHED;
-			DP_INFO(edev, "Enabling Tx unmatched flag for VF\n");
+			flags.tx_accept_filter |=
+						(ECORE_ACCEPT_UCAST_UNMATCHED |
+						 ECORE_ACCEPT_MCAST_UNMATCHED);
+			DP_INFO(edev, "Enabling Tx unmatched flags for VF\n");
 		}
 	} else if (type == QED_FILTER_RX_MODE_TYPE_MULTI_PROMISC) {
 		flags.rx_accept_filter |= ECORE_ACCEPT_MCAST_UNMATCHED;
-	} else if (type == (QED_FILTER_RX_MODE_TYPE_MULTI_PROMISC |
-				QED_FILTER_RX_MODE_TYPE_PROMISC)) {
-		flags.rx_accept_filter |= ECORE_ACCEPT_UCAST_UNMATCHED |
-			ECORE_ACCEPT_MCAST_UNMATCHED;
 	}
 
 	return ecore_filter_accept_cmd(edev, 0, flags, false, false,
@@ -1420,16 +1419,13 @@ qede_link_update(struct rte_eth_dev *eth_dev, __rte_unused int wait_to_complete)
 
 static int qede_promiscuous_enable(struct rte_eth_dev *eth_dev)
 {
-	struct qede_dev *qdev = eth_dev->data->dev_private;
-	struct ecore_dev *edev = &qdev->edev;
+	enum _ecore_status_t ecore_status;
+	struct qede_dev *qdev = QEDE_INIT_QDEV(eth_dev);
+	struct ecore_dev *edev = QEDE_INIT_EDEV(qdev);
 	enum qed_filter_rx_mode_type type = QED_FILTER_RX_MODE_TYPE_PROMISC;
-	enum _ecore_status_t ecore_status;
 
 	PMD_INIT_FUNC_TRACE(edev);
 
-	if (rte_eth_allmulticast_get(eth_dev->data->port_id) == 1)
-		type |= QED_FILTER_RX_MODE_TYPE_MULTI_PROMISC;
-
 	ecore_status = qed_configure_filter_rx_mode(eth_dev, type);
 
 	return ecore_status >= ECORE_SUCCESS ? 0 : -EAGAIN;
@@ -1803,9 +1799,6 @@ static int qede_allmulticast_enable(struct rte_eth_dev *eth_dev)
 	    QED_FILTER_RX_MODE_TYPE_MULTI_PROMISC;
 	enum _ecore_status_t ecore_status;
 
-	if (rte_eth_promiscuous_get(eth_dev->data->port_id) == 1)
-		type |= QED_FILTER_RX_MODE_TYPE_PROMISC;
-
 	ecore_status = qed_configure_filter_rx_mode(eth_dev, type);
 
 	return ecore_status >= ECORE_SUCCESS ? 0 : -EAGAIN;
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2020-07-24 12:53:50.954777550 +0100
+++ 0061-net-qede-fix-multicast-drop-in-promiscuous-mode.patch	2020-07-24 12:53:48.283006385 +0100
@@ -1,15 +1,16 @@
-From b10231aed1edb9cdd74a0a021a38267255952f00 Mon Sep 17 00:00:00 2001
+From 889b24bdd1573d9839df7ffebae1e04592cdd090 Mon Sep 17 00:00:00 2001
 From: Devendra Singh Rawat <dsinghrawat at marvell.com>
 Date: Thu, 18 Jun 2020 13:45:55 +0530
 Subject: [PATCH] net/qede: fix multicast drop in promiscuous mode
 
+[ upstream commit b10231aed1edb9cdd74a0a021a38267255952f00 ]
+
 After enabling promiscuous mode all packets whose destination MAC
 address is a multicast address were being dropped. This fix configures
 H/W to receive all traffic in promiscuous mode. Promiscuous mode also
 overrides allmulticast mode on/off status.
 
 Fixes: 40e9f6fc1558 ("net/qede: enable VF-VF traffic with unmatched dest address")
-Cc: stable at dpdk.org
 
 Signed-off-by: Devendra Singh Rawat <dsinghrawat at marvell.com>
 Signed-off-by: Igor Russkikh <irusskikh at marvell.com>
@@ -19,10 +20,10 @@
  1 file changed, 9 insertions(+), 16 deletions(-)
 
 diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c
-index c4f8f1258..84d2d2c03 100644
+index 2a1c82ac9..abb82d336 100644
 --- a/drivers/net/qede/qede_ethdev.c
 +++ b/drivers/net/qede/qede_ethdev.c
-@@ -625,17 +625,16 @@ qed_configure_filter_rx_mode(struct rte_eth_dev *eth_dev,
+@@ -551,17 +551,16 @@ qed_configure_filter_rx_mode(struct rte_eth_dev *eth_dev,
  		ECORE_ACCEPT_BCAST;
  
  	if (type == QED_FILTER_RX_MODE_TYPE_PROMISC) {
@@ -46,7 +47,7 @@
  	}
  
  	return ecore_filter_accept_cmd(edev, 0, flags, false, false,
-@@ -1502,16 +1501,13 @@ qede_link_update(struct rte_eth_dev *eth_dev, __rte_unused int wait_to_complete)
+@@ -1420,16 +1419,13 @@ qede_link_update(struct rte_eth_dev *eth_dev, __rte_unused int wait_to_complete)
  
  static int qede_promiscuous_enable(struct rte_eth_dev *eth_dev)
  {
@@ -66,7 +67,7 @@
  	ecore_status = qed_configure_filter_rx_mode(eth_dev, type);
  
  	return ecore_status >= ECORE_SUCCESS ? 0 : -EAGAIN;
-@@ -1885,9 +1881,6 @@ static int qede_allmulticast_enable(struct rte_eth_dev *eth_dev)
+@@ -1803,9 +1799,6 @@ static int qede_allmulticast_enable(struct rte_eth_dev *eth_dev)
  	    QED_FILTER_RX_MODE_TYPE_MULTI_PROMISC;
  	enum _ecore_status_t ecore_status;
  


More information about the stable mailing list