From a91fb48a8c248293f1035cdd8b36ad712ae9478f Mon Sep 17 00:00:00 2001 From: Balazs Nemeth Date: Wed, 23 Dec 2020 15:15:49 +0100 Subject: [PATCH] net/qede: fix promiscuous enable When calling rte_eth_promiscuous_enable(port_id) followed by rte_eth_allmulticast_enable(port_id), the port is not in promisc mode anymore. This patch ensures that promisc mode takes precedence over allmulticast mode fixing the regression introduced by b10231aed1ed. Fixes: b10231aed1ed ("net/qede: fix multicast drop in promiscuous mode") Cc: stable@dpdk.org Signed-off-by: Balazs Nemeth Acked-by: Rasesh Mody --- drivers/net/qede/qede_ethdev.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c index 549013557c..3bec62d828 100644 --- a/drivers/net/qede/qede_ethdev.c +++ b/drivers/net/qede/qede_ethdev.c @@ -1885,6 +1885,8 @@ 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