Skip to content

netlink: route table ids and bridge vlan on FreeBSD - #6

Merged
ahze merged 1 commit into
mainfrom
build/route-tables-bridge-vlan
Nov 12, 2026
Merged

ahze merged 1 commit into
mainfrom
build/route-tables-bridge-vlan

Conversation

@ahze

@ahze ahze commented Nov 12, 2026

Copy link
Copy Markdown
Member

FreeBSD has no RT_TABLE_* in the libc crate and its tables are FIBs: the
default FIB is 0 and the kernel reads the FIB from RTA_TABLE, so both the
main and the unspec table id are 0 in the u8 header slot. Keep the Linux
values from libc behind cfg.

The bridge vlan message is AF_BRIDGE, which FreeBSD does not have. Reject
the vlan option at validation on non-Linux and give set_vlan_id a stub
there so the bridge driver does not need its own cfg.

FreeBSD has no RT_TABLE_* in the libc crate and its tables are FIBs: the
default FIB is 0 and the kernel reads the FIB from RTA_TABLE, so both the
main and the unspec table id are 0 in the u8 header slot. Keep the Linux
values from libc behind cfg.

The bridge vlan message is AF_BRIDGE, which FreeBSD does not have. Reject
the vlan option at validation on non-Linux and give set_vlan_id a stub
there so the bridge driver does not need its own cfg.

Signed-off-by: Michael Johnson <buhnux@gmail.com>
@ahze
ahze merged commit fcbc869 into main Nov 12, 2026
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant