From: Kalesh AP <kalesh-anakkur.pura...@broadcom.com> When the user tries to add more number of Mcast MAC addresses than supported by the port, driver puts port into Mcast promiscuous mode. It may be useful to the user to know that Mcast promiscuous mode is turned on.
Similarly added a log when Mcast promiscuous mode is turned off. Signed-off-by: Kalesh AP <kalesh-anakkur.pura...@broadcom.com> Reviewed-by: Somnath Kotur <somnath.ko...@broadcom.com> Reviewed-by: Ajit Khaparde <ajit.khapa...@broadcom.com> --- drivers/net/bnxt/bnxt_ethdev.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c index acf7e6e46e..f398838ea8 100644 --- a/drivers/net/bnxt/bnxt_ethdev.c +++ b/drivers/net/bnxt/bnxt_ethdev.c @@ -2931,12 +2931,18 @@ bnxt_dev_set_mc_addr_list_op(struct rte_eth_dev *eth_dev, bp->nb_mc_addr = nb_mc_addr; if (nb_mc_addr > BNXT_MAX_MC_ADDRS) { + PMD_DRV_LOG(INFO, "Number of Mcast MACs added (%u) exceeded Max supported (%u)\n", + nb_mc_addr, BNXT_MAX_MC_ADDRS); + PMD_DRV_LOG(INFO, "Turning on Mcast promiscuous mode\n"); vnic->flags |= BNXT_VNIC_INFO_ALLMULTI; goto allmulti; } /* TODO Check for Duplicate mcast addresses */ - vnic->flags &= ~BNXT_VNIC_INFO_ALLMULTI; + if (vnic->flags & BNXT_VNIC_INFO_ALLMULTI) { + PMD_DRV_LOG(INFO, "Turning off Mcast promiscuous mode\n"); + vnic->flags &= ~BNXT_VNIC_INFO_ALLMULTI; + } for (i = 0; i < nb_mc_addr; i++) rte_ether_addr_copy(&mc_addr_set[i], &bp->mcast_addr_list[i]); -- 2.39.2 (Apple Git-143)
smime.p7s
Description: S/MIME Cryptographic Signature