Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 26 Sep 2022 08:28:33 GMT
From:      =?utf-8?Q?Kornel=20Dul=C4=99ba?= <kd@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 7b8bb67135f2 - stable/13 - igc: Don't start in promiscious mode by default
Message-ID:  <202209260828.28Q8SX1Q010833@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by kd:

URL: https://cgit.FreeBSD.org/src/commit/?id=7b8bb67135f24f6770162deef12b0d34ff4e6677

commit 7b8bb67135f24f6770162deef12b0d34ff4e6677
Author:     Hubert Mazur <hum@semihalf.com>
AuthorDate: 2022-09-16 11:37:12 +0000
Commit:     Kornel Dulęba <kd@FreeBSD.org>
CommitDate: 2022-09-26 07:33:58 +0000

    igc: Don't start in promiscious mode by default
    
    The igc driver always sets the promiscious mode during initialization,
    ignoring what is set in ifp.
    Fix this by checking the interface flags and setting mode appropriately.
    
    Reviewed by:    grehan
    Obtained from:  Semihalf
    Sponsored by:   Stormshield
    MFC after:      1 week
    Differential Revision: https://reviews.freebsd.org/D36591
    
    (cherry picked from commit 55760984d56bb1a4c6bc8040ae022353667258e2)
---
 sys/dev/igc/if_igc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/dev/igc/if_igc.c b/sys/dev/igc/if_igc.c
index 607b893c9ab8..29a234702303 100644
--- a/sys/dev/igc/if_igc.c
+++ b/sys/dev/igc/if_igc.c
@@ -859,7 +859,7 @@ igc_if_init(if_ctx_t ctx)
 	}
 
 	/* Don't lose promiscuous settings */
-	igc_if_set_promisc(ctx, IFF_PROMISC);
+	igc_if_set_promisc(ctx, if_getflags(ifp));
 	igc_clear_hw_cntrs_base_generic(&adapter->hw);
 
 	if (adapter->intr_type == IFLIB_INTR_MSIX) /* Set up queue routing */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202209260828.28Q8SX1Q010833>