The branch main has been updated by kbowling:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=98bdf63f6e94be42a1787de73608de15bcb3419a

commit 98bdf63f6e94be42a1787de73608de15bcb3419a
Author:     Yogesh Bhosale <[email protected]>
AuthorDate: 2026-02-01 17:27:36 +0000
Commit:     Kevin Bowling <[email protected]>
CommitDate: 2026-02-01 17:27:36 +0000

    ice(4): Handle allmulti flag in ice_if_promisc_set function
    
    In the ice_if_promisc_set function, the driver currently disables the
    IFF_ALLMULTI flag, thereby preventing the activation of multicast mode.
    To address this issue, implement appropriate handling to ensure the
    flag is managed correctly.
    
    Signed-off-by: Yogesh Bhosale <[email protected]>
    
    Tested by:      Gowthamkumar K S <[email protected]>
    MFC after:      1 week
    Differential Revision:  https://reviews.freebsd.org/D54186
---
 sys/dev/ice/if_ice_iflib.c | 25 ++++++++++++++++++++-----
 1 file changed, 20 insertions(+), 5 deletions(-)

diff --git a/sys/dev/ice/if_ice_iflib.c b/sys/dev/ice/if_ice_iflib.c
index 1469d2916465..6ea539d52e02 100644
--- a/sys/dev/ice/if_ice_iflib.c
+++ b/sys/dev/ice/if_ice_iflib.c
@@ -1907,15 +1907,13 @@ ice_if_promisc_set(if_ctx_t ctx, int flags)
        
        ice_set_default_promisc_mask(promisc_mask);
 
-       if (multi_enable)
-               return (EOPNOTSUPP);
-
        if (promisc_enable) {
                status = ice_set_vsi_promisc(hw, sc->pf_vsi.idx,
                                             promisc_mask, 0);
                if (status && status != ICE_ERR_ALREADY_EXISTS) {
                        device_printf(dev,
-                                     "Failed to enable promiscuous mode for PF 
VSI, err %s aq_err %s\n",
+                                     "Failed to enable promiscuous mode for "
+                                     "PF VSI, err %s aq_err %s\n",
                                      ice_status_str(status),
                                      ice_aq_str(hw->adminq.sq_last_status));
                        return (EIO);
@@ -1925,11 +1923,28 @@ ice_if_promisc_set(if_ctx_t ctx, int flags)
                                               promisc_mask, 0);
                if (status) {
                        device_printf(dev,
-                                     "Failed to disable promiscuous mode for 
PF VSI, err %s aq_err %s\n",
+                                     "Failed to disable promiscuous mode for"
+                                     " PF VSI, err %s aq_err %s\n",
                                      ice_status_str(status),
                                      ice_aq_str(hw->adminq.sq_last_status));
                        return (EIO);
                }
+
+               if (multi_enable) {
+                       ice_clear_bit(ICE_PROMISC_UCAST_TX, promisc_mask);
+                       ice_clear_bit(ICE_PROMISC_UCAST_RX, promisc_mask);
+                       status = ice_set_vsi_promisc(hw, sc->pf_vsi.idx,
+                                                    promisc_mask, 0);
+                       if (status && status != ICE_ERR_ALREADY_EXISTS) {
+                               device_printf(dev,
+                                             "Failed to enable allmulti mode "
+                                             "for PF VSI, err %s aq_err %s\n",
+                                             ice_status_str(status),
+                                             ice_aq_str(
+                                             hw->adminq.sq_last_status));
+                               return (EIO);
+                       }
+               }
        }
 
        return (0);

Reply via email to