Skip to content

Commit

Permalink
net/qede: fix promiscuous enable
Browse files Browse the repository at this point in the history
[ upstream commit a91fb48 ]

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 b10231a.

Fixes: b10231a ("net/qede: fix multicast drop in promiscuous mode")

Signed-off-by: Balazs Nemeth <bnemeth@redhat.com>
Acked-by: Rasesh Mody <rmody@marvell.com>
  • Loading branch information
bn222 authored and cpaelzer committed Feb 3, 2021
1 parent 4c52a6f commit d900b4d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/qede/qede_ethdev.c
Original file line number Diff line number Diff line change
Expand Up @@ -1796,6 +1796,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;
Expand Down

0 comments on commit d900b4d

Please sign in to comment.