From nobody Mon May 15 05:06:07 2023 X-Original-To: dev-commits-src-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4QKS4v4XFVz4B8K7; Mon, 15 May 2023 05:06:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4QKS4v4509z3DCv; Mon, 15 May 2023 05:06:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1684127167; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8jH9r4dUEI3DsdSTPcCoBU/1yHKQ9wHqH0O60gVSOEA=; b=PDv/WFEmQtZMBd12DBqAnrV+BdVSZhbdcwUukfgkmiriq2WrnL8CWBrwoNX9EITtGzh4PL iZvNCitqxBhegt7pFz+SsC1al6bX/sZ6nng7yXR6APDwaKYJLHWQNtlzdqXb9zM73fX8Ee RY7vBdPbVTCNayVTYXvk14CrCbK2otSf04a+rKxxO6ktTsPEV1NCLQ+/nOZDIokEJkWZal VcMbkqDJNm2K4604i9W2YZP73/6lIjxSjdNvvM5JTvjqc+KSIlYKWhjNUnj63fU84c/zJ9 upO9YXj51tSU5TRDfgB+XzM/bh/QC9fy4KJSsBszbwkok0atrx9gnbzxLSZHEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1684127167; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8jH9r4dUEI3DsdSTPcCoBU/1yHKQ9wHqH0O60gVSOEA=; b=lppGkv4AgQBAuC41B5Nbr3o7mlIjKme7T0bjXUOJfikFS8Nf6vy5WS0UUDdi+Tp6H/l16E gl2DFjI5/LA0UpMgM9WeyhNdegLeu2pvhTVuI83E7sqx5bPxW6XQ1bpe8L7w95kr7PGiqS BTLUKpFsh2SdNVuRFnqPvqS1mVWLmYzrgqVQTHyElVIDz3kn2xjO83Z1VEc0MBXQuHusyt bLelij52fLjBaaiAvoCbRGZM7K+iBfXiE9/dar+sAKWb9ZpRzpZXN6fUJe+g/UKrh1jRzf 6iuFNc2nop0wr6Gmoz0JVkHbWG+AbGeUfQgUcsWzjplAl+j057U23N78wL9vVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1684127167; a=rsa-sha256; cv=none; b=gpjbaIdQNki8hjChT4jMA4vzmcKaoTUXZyZHt6slQD5iNz2ihpBl/eovxY3TEoBxu1v/7x fYl6hpzDNBlTsNmNP1bTOUBlwpdCRAJOLEa+nywcq0bSm71pyMAAyXIG96+uQCvYoCynkO KP1O1JaIoPeMqaB9xg4gIxJvTUqlBmmuOcADK2vOnmy8Z2kR8dOsUsV8bjN6CkCFoNiGxT PxTcVrv24AX5HSRxJmVZPf+1JCCUsqMYWNv1c17l9YVpVv3PsS4mMEIdw50Emgbm+PWv2l eaKreWO9M6ISvPWwul7vi0EiUfx6csx10U9doF1hhGhe7c5/E448EHkB+myC0Q== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4QKS4v3224zSXb; Mon, 15 May 2023 05:06:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 34F567CZ021178; Mon, 15 May 2023 05:06:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 34F567Wq021177; Mon, 15 May 2023 05:06:07 GMT (envelope-from git) Date: Mon, 15 May 2023 05:06:07 GMT Message-Id: <202305150506.34F567Wq021177@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: 5cb5b368829d - stable/12 - e1000: fix VLAN 0 List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 5cb5b368829dd075bec55ada6c1374538ec7c6d0 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=5cb5b368829dd075bec55ada6c1374538ec7c6d0 commit 5cb5b368829dd075bec55ada6c1374538ec7c6d0 Author: Kristof Provost AuthorDate: 2023-05-10 16:26:29 +0000 Commit: Kristof Provost CommitDate: 2023-05-15 04:49:51 +0000 e1000: fix VLAN 0 VLAN 0 essentially means "Treat as untagged, but with priority bits", and is used by some ISPs. On igb/em interfaces we did not receive packets with VLAN tag 0 unless vlanhwfilter was disabled. This can be fixed by explicitly listing VLAN 0 in the hardware VLAN filter (VFTA). Do this from em_setup_vlan_hw_support(), where we already (re-)write the VFTA. Reviewed by: kbowling Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D40046 (cherry picked from commit 0229fab2fe0eed843ebec98fd31b7d49bb2e8438) --- sys/dev/e1000/if_em.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c index 8a489c48bf85..3e41e1e0bff1 100644 --- a/sys/dev/e1000/if_em.c +++ b/sys/dev/e1000/if_em.c @@ -3671,8 +3671,10 @@ em_setup_vlan_hw_support(if_ctx_t ctx) /* * A soft reset zero's out the VFTA, so * we need to repopulate it now. + * We also insert VLAN 0 in the filter list, so we pass VLAN 0 tagged + * traffic through. This will write the entire table. */ - em_if_vlan_filter_write(sc); + em_if_vlan_register(ctx, 0); /* Enable the Filter Table */ em_if_vlan_filter_enable(sc);