epo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4f4QrY6NbPz9ln for ; Mon, 02 Feb 2026 12:28:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 20f39 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 02 Feb 2026 12:28:29 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: e63ee5fedb8d - main - e1000: Fix setting the promiscuous mode List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e63ee5fedb8dab51f1bd6d24cc650b68d9663db5 Auto-Submitted: auto-generated Date: Mon, 02 Feb 2026 12:28:29 +0000 Message-Id: <6980986d.20f39.48711372@gitrepo.freebsd.org> The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=e63ee5fedb8dab51f1bd6d24cc650b68d9663db5 commit e63ee5fedb8dab51f1bd6d24cc650b68d9663db5 Author: Zhenlei Huang AuthorDate: 2026-02-02 12:26:31 +0000 Commit: Zhenlei Huang CommitDate: 2026-02-02 12:26:31 +0000 e1000: Fix setting the promiscuous mode The variable reg_rctl stores the value read from reg E1000_RCTL. It may contain bits E1000_RCTL_VFE and E1000_RCTL_CFIEN which control VLAN hardware filter feature. The promiscuous mode implies all tagged or untagged packets should be accepted, so the VLAN hardware filter feature should be disabled when enabling the promiscuous mode. Calling em_if_vlan_filter_disable() did the task, but later writing the value of reg_rctl back to the reg E1000_RCTL may restore the feature. Move the calling of em_if_vlan_filter_disable() after writing the reg to fix that. PR: 292759 Reviewed by: kbowling Tested by: vova@zote.me Fixes: 2796f7cab107 e1000: Fix up HW vlan ops MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D54973 --- sys/dev/e1000/if_em.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c index 7d7655a7ae6f..4d7bc794a0b2 100644 --- a/sys/dev/e1000/if_em.c +++ b/sys/dev/e1000/if_em.c @@ -2106,11 +2106,11 @@ em_if_set_promisc(if_ctx_t ctx, int flags) if (flags & IFF_PROMISC) { reg_rctl |= (E1000_RCTL_UPE | E1000_RCTL_MPE); - em_if_vlan_filter_disable(sc); /* Turn this on if you want to see bad packets */ if (em_debug_sbp) reg_rctl |= E1000_RCTL_SBP; E1000_WRITE_REG(&sc->hw, E1000_RCTL, reg_rctl); + em_if_vlan_filter_disable(sc); } else { if (flags & IFF_ALLMULTI) { reg_rctl |= E1000_RCTL_MPE;