<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/netinet6/ip6_mroute.c, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=main</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2026-04-04T23:10:45Z</updated>
<entry>
<title>Fix nooptions VIMAGE build</title>
<updated>2026-04-04T23:10:45Z</updated>
<author>
<name>Andrew Gallatin</name>
<email>gallatin@FreeBSD.org</email>
</author>
<published>2026-04-04T23:10:45Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=3f79bc9ca336f634e1afa262ccf5155882550a8a'/>
<id>urn:sha1:3f79bc9ca336f634e1afa262ccf5155882550a8a</id>
<content type='text'>
The recent FIBify commits deref struct thread without including
sys/proc.h, which can result in a compiler error.  This becomes
apparent when building with LINT-NOVIMAGE, as net/vnet.h includes
sys/proc.h.  Fix this by directly including sys/proc.h

Fixes: 4c486fe40267 ("ip_mroute: FIBify"), 0bb9c2b665d9 ("ip6_mroute: FIBify")
</content>
</entry>
<entry>
<title>ip6_mroute: Fix the type name in sysctl_mfctable()</title>
<updated>2026-04-01T11:16:15Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-04-01T11:13:05Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=0dbbed21a643f6c95bebe23008a332ff68adb203'/>
<id>urn:sha1:0dbbed21a643f6c95bebe23008a332ff68adb203</id>
<content type='text'>
No functional change since apparently it's fine to compute the size of
a pointer type when the base type is undefined.

Fixes:	0bb9c2b665d9 ("ip6_mroute: FIBify")
</content>
</entry>
<entry>
<title>ip6_mroute: Handle interface detach events</title>
<updated>2026-03-30T16:08:21Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:33:32Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a1c042a9641c9df08010e87d0928703849ff9853'/>
<id>urn:sha1:a1c042a9641c9df08010e87d0928703849ff9853</id>
<content type='text'>
When an interface goes away we need to make sure the v6 multicast
routing tables don't carry any dangling references to the ifnet.  The v4
code handles this already.  Copy the approach there and use an
eventhandler to purge the corresponding MIF, if one exists, and further
go through all routes in the FIB and remove references to the interface.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55246
</content>
</entry>
<entry>
<title>ip6_mroute: Pass the multicast interface number directly to del_m6if()</title>
<updated>2026-03-30T16:08:21Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:33:11Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=82272cbf56aa5646611c6f1049501cc345fcf6ec'/>
<id>urn:sha1:82272cbf56aa5646611c6f1049501cc345fcf6ec</id>
<content type='text'>
There's no need to pass a pointer to the interface number.  No
functional change intended.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55245
</content>
</entry>
<entry>
<title>ip6_mroute: FIBify</title>
<updated>2026-03-30T16:08:21Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:31:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=0bb9c2b665d90934ae16eee152b6b4f4f4be0dd5'/>
<id>urn:sha1:0bb9c2b665d90934ae16eee152b6b4f4f4be0dd5</id>
<content type='text'>
Modify the control plane (ioctl and socket option handlers) to use the
routing socket FIB to index into the mfctable array.  Modify the
forwarding plane to use the mbuf's FIB to determine which routing table
to use.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55242
</content>
</entry>
<entry>
<title>ip(6)_mroute: Grow the routing tables when the number of FIBs changes</title>
<updated>2026-03-30T16:08:21Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:30:38Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=97a4bc9a0da7cd63c660ce59a9dd7c87efe1f218'/>
<id>urn:sha1:97a4bc9a0da7cd63c660ce59a9dd7c87efe1f218</id>
<content type='text'>
Use the new rtnumfibs_change event to expand the mfctable array when the
number of FIBs increases.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55240
</content>
</entry>
<entry>
<title>ip6_mroute: Start putting global variables into a structure</title>
<updated>2026-03-30T16:08:20Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-03-30T13:29:01Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a223d6c489c7ea9a384f3d2bbda1b05b00d4502d'/>
<id>urn:sha1:a223d6c489c7ea9a384f3d2bbda1b05b00d4502d</id>
<content type='text'>
As in the IPv4 version of this change, I added a struct mf6ctable
structure which holds all global routing table state, soon to become
per-FIB state.

Note that much of the v6 multicast routing code was not VNETified; this
change fixes that too.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55238
</content>
</entry>
<entry>
<title>ip_mroute: Make the routing socket private</title>
<updated>2026-02-13T19:35:18Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-02-13T16:50:18Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=d19fd2f349226116f7effb281baa1eb32b8292e7'/>
<id>urn:sha1:d19fd2f349226116f7effb281baa1eb32b8292e7</id>
<content type='text'>
I have some patches which make ip_mroute and ip6_mroute multi-FIB-aware.
This enables running per-FIB routing daemons, each of which has a
separate routing socket.

Several places in the network stack check whether multicast routing is
configured by checking whether the multicast routing socket is non-NULL.
This doesn't directly translate in my proposed scheme, as each FIB would
have its own socket.  I'd like to modify the ip(6)_mroute code to store
all state, including the socket, in a per-FIB structure.  So, take a
step towards that and 1) hide the socket, 2) add a boolean flag which
indicates whether a multicast router is registered.

Reviewed by:	pouria, zlei, glebius, adrian
MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55236
</content>
</entry>
<entry>
<title>ip6_mroute: Deindent some code in ip6_mdq()</title>
<updated>2026-02-10T13:45:06Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-02-09T22:52:20Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=d8f7a7b44a951368d637bbbdc06c28ffd6331d76'/>
<id>urn:sha1:d8f7a7b44a951368d637bbbdc06c28ffd6331d76</id>
<content type='text'>
Deal with the mifi &gt;= nummifs case early so that we can de-indent the
rest of the code.  This also ensures that the debug log (compiled out by
default) doesn't perform an out-of-bounds access.

Remove a bogus NULL test in an inner loop while here.

No functional change intended.

Reviewed by:	glebius
MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D55059
</content>
</entry>
<entry>
<title>ip6_mroute: Remove an unhelpful comment</title>
<updated>2026-02-02T16:54:54Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2026-02-02T14:59:20Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a45fb94801dffd414bdb1981def0e977ef0c774f'/>
<id>urn:sha1:a45fb94801dffd414bdb1981def0e977ef0c774f</id>
<content type='text'>
ifnets already track if_allmulti() calls in the if_amcount field.  That
field is older than the comment, so I'm not exactly sure what the intent
was; let's just remove it.

MFC after:	2 weeks
Sponsored by:	Stormshield
Sponsored by:	Klara, Inc.
</content>
</entry>
</feed>
