It's just a display issue, normal and span members work as intended. To reproduce the problem (on 15.0-RELEASE): # ifconfig bridge0 create # ifconfig tap0 create # ifconfig tap1 create # ifconfig bridge0 addm tap0 # ifconfig bridge0 bridge0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=10<VLAN_HWTAGGING> ether 58:9c:fc:10:ab:d7 id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15 maxage 20 holdcnt 6 proto rstp maxaddr 2000 timeout 1200 root id 00:00:00:00:00:00 priority 0 ifcost 0 port 0 bridge flags=0<> member: tap0 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP> port 4 priority 128 path cost 2000000 vlan protocol 802.1q groups: bridge nd6 options=9<PERFORMNUD,IFDISABLED> # ifconfig bridge0 span tap1 # ifconfig bridge0 bridge0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=10<VLAN_HWTAGGING> ether 58:9c:fc:10:ab:d7 groups: bridge # ---------------------------------------- For reference, on 14.3-RELEASE, we get: # ifconfig bridge0 create # ifconfig tap0 create # ifconfig tap1 create # ifconfig bridge0 addm tap0 # ifconfig bridge0 span tap1 # ifconfig bridge0 bridge0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=0 ether 58:9c:fc:10:b3:24 id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15 maxage 20 holdcnt 6 proto rstp maxaddr 2000 timeout 1200 root id 00:00:00:00:00:00 priority 0 ifcost 0 port 0 member: tap0 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP> ifmaxaddr 0 port 4 priority 128 path cost 2000000 member: tap1 flags=8<SPAN> ifmaxaddr 0 port 5 priority 128 path cost 2000000 groups: bridge nd6 options=9<PERFORMNUD,IFDISABLED> #
I'm looking at the code. I think the problem comes from sbin/ifconfig/ifbridge.c, line 212: static void bridge_status(if_ctx *ctx) { struct ifconfig_bridge_status *bridge; struct ifbropreq *params; const char *pad, *prefix; uint8_t lladdr[ETHER_ADDR_LEN]; uint16_t bprio; if (ifconfig_bridge_get_bridge_status(lifh, ctx->ifname, &bridge) == -1) return; params = bridge->params; PV2ID(params->ifbop_bridgeid, bprio, lladdr); printf("\tid %s priority %u hellotime %u fwddelay %u\n", (...snip...) The function ifconfig_bridge_get_bridge_status() could return -1 when a span interface is present as a bridge member, thus stopping all the subsequent prints (as we see in the ifconfig output). This function is located in lib/libifconfig/libifconfig_bridge.c. Maybe one of the two last commits is responsible for this issue.
Created attachment 267422 [details] Add scan the span list for bridge_lookup_member This patch is for 15.0-RELEASE. ------------------------------- My first intuition was right. It's well the call to ifconfig_bridge_get_bridge_status() in sbin/ifconfig/ifbridge.c which answers -1 when a span member is present in the bridge. ifconfig_bridge_get_bridge_status() is defined in lib/libifconfig/libifconfig_bridge.c. The error comes from these lines: if (ifconfig_bridge_ioctlwrap(h, name, BRDGGIFVLANSET, &vreq, sizeof(vreq), false) != 0) { goto err; } Looking at sys/net/if_bridge.c, the function bridge_ioctl_gifvlanset() is failed in case of a span member at: bif = bridge_lookup_member(sc, req->bv_ifname); And, finally, inspecting bridge_lookup_member(), I saw that it looks only in the normal members list, not in the span list (&sc->sc_spanlist). So, I just added some lines to look into the span list before to return NULL.
Created attachment 267434 [details] Add scan the span list for bridge_lookup_member ^Triage: rebase patch To make it easier for committers to apply the patches and merge them, please use git and run `git format-patch @~1`, that makes it most convenient.
Created attachment 267445 [details] Add scanning of span list for bridge_lookup_member
(In reply to Simon Wollwage from comment #3) Sorry, git is over complicated for me, yet I use it. I wonder why your patch is altering bridge_ioctl_gifvlanset() since I didn't touch to its function code. Following your guide, I get what this attachement.
Will this patch be committed for 15.1-RELEASE?
thank you for the bug report and the patch. i decided to fix this a different way, by not attempting BRDGGIFVLANSET for span members. the fix should be in 15.1-RELEASE.
(In reply to Lexi Winter from comment #7) I suppose there is a good reason for that. However, the function bridge_lookup_member() in the kmod answers NULL in case of a span member. So, a span member isn't a member. Is this ok for you?
i think it's debatable whether a span member is "a bridge member" or not; however, changing bridge_lookup_member() to return span members opens a huge can of worms--e.g., can you now configure VLANs on span members, even though this doesn't work or make sense?--if we want to fix this for 15.1, this change is the least invasive way to do that.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=454322c08b8aa181939c8d920472f03cfd591032 commit 454322c08b8aa181939c8d920472f03cfd591032 Author: Lexi Winter <ivy@FreeBSD.org> AuthorDate: 2026-04-29 03:11:20 +0000 Commit: Lexi Winter <ivy@FreeBSD.org> CommitDate: 2026-04-29 03:12:20 +0000 libifconfig: Skip bridge VLAN config for span members bridge(4) doesn't support BRDGGIFVLANSET for span members, which means if a span interface is configured, libifconfig will fail to fetch bridge members. Skip this for IFBIF_SPAN members. PR: 292634 MFC after: 3 days Reported by: Emrion <kmachine@free.fr> Reviewed by: pouria, zlei Sponsored by: https://www.patreon.com/bsdivy Differential Revision: https://reviews.freebsd.org/D56694 lib/libifconfig/libifconfig_bridge.c | 5 +++++ 1 file changed, 5 insertions(+)
(In reply to Lexi Winter from comment #9) I tested your patch, and without surprise, it works for me. I won't contrary you about the useless of VLAN concerning span member. As, even for me, it makes sense. :-) What is worrying me it's what devs define exactly as a bridge member. Because if it is not clear for all, more serious bugs will come.
A commit in branch stable/15 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=0a919e2a9265b5cdaeb2c5d51c29791b4eb7335c commit 0a919e2a9265b5cdaeb2c5d51c29791b4eb7335c Author: Lexi Winter <ivy@FreeBSD.org> AuthorDate: 2026-04-29 03:11:20 +0000 Commit: Lexi Winter <ivy@FreeBSD.org> CommitDate: 2026-05-04 00:14:37 +0000 libifconfig: Skip bridge VLAN config for span members bridge(4) doesn't support BRDGGIFVLANSET for span members, which means if a span interface is configured, libifconfig will fail to fetch bridge members. Skip this for IFBIF_SPAN members. PR: 292634 MFC after: 3 days Reported by: Emrion <kmachine@free.fr> Reviewed by: pouria, zlei Sponsored by: https://www.patreon.com/bsdivy Differential Revision: https://reviews.freebsd.org/D56694 (cherry picked from commit 454322c08b8aa181939c8d920472f03cfd591032) lib/libifconfig/libifconfig_bridge.c | 5 +++++ 1 file changed, 5 insertions(+)
^Triage: apparently no MFC to 14 is planned.
A commit in branch releng/15.1 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=5f901e157aafa6ed4550fe39dbc121f7668459b7 commit 5f901e157aafa6ed4550fe39dbc121f7668459b7 Author: Lexi Winter <ivy@FreeBSD.org> AuthorDate: 2026-04-29 03:11:20 +0000 Commit: Lexi Winter <ivy@FreeBSD.org> CommitDate: 2026-05-05 15:03:45 +0000 libifconfig: Skip bridge VLAN config for span members bridge(4) doesn't support BRDGGIFVLANSET for span members, which means if a span interface is configured, libifconfig will fail to fetch bridge members. Skip this for IFBIF_SPAN members. PR: 292634 MFC after: 3 days Reported by: Emrion <kmachine@free.fr> Reviewed by: pouria, zlei Approved by: re (cperciva) Sponsored by: https://www.patreon.com/bsdivy Differential Revision: https://reviews.freebsd.org/D56694 (cherry picked from commit 454322c08b8aa181939c8d920472f03cfd591032) (cherry picked from commit 0a919e2a9265b5cdaeb2c5d51c29791b4eb7335c) lib/libifconfig/libifconfig_bridge.c | 5 +++++ 1 file changed, 5 insertions(+)