Repository navigation
Conversation
The bridge port "Multicast routing" dropdown mapped "Never" to the empty value, so choosing it removed the option instead of writing 0. As netifd only writes brport/multicast_router when the option is present, the port then kept the kernel init default (MDB_RTR_TYPE_TEMP_QUERY == 1) and was still learned as a multicast router port. Additionally, 0 was not part of the choice list, so an existing `option multicast_router '0'` rendered with nothing selected and was silently dropped when saving the page, reverting the port to 1. Add an explicit `''` -> "Auto (Learn)" entry which drops the option so that the kernel default (1, learn) applies, and list the real values 0, 1 and 2 so that "Never" really writes 0 and existing 0/1/2 values are preserved. Keep the explicit 1 entry as it is not the same state as a missing option: netifd re-applies it on every reload. Link: openwrt#9087 Signed-off-by: Jebbs Chiu <qjebbs@gmail.com>
qjebbs
force-pushed
the
fix-multicast-router-option
branch
from
October 10, 2026 09:55
a671ed0 to
21baa10
Compare
openwrt-ai
reviewed
Oct 10, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the two issues reported in #9087.
1. "Never" did not disable the port
The bridge port Multicast routing dropdown mapped "Never" to the empty
value, so selecting it removed the UCI option instead of writing
0.netifd only writes
brport/multicast_routerwhen the option is present,so the port kept the kernel init default (
MDB_RTR_TYPE_TEMP_QUERY== 1)and was still treated as a multicast router port on general IGMP queries.
2. An existing
option multicast_router '0'was silently dropped0was not part of the choice list, so the widget rendered with nothingselected and saving the page removed the option, reverting the port to 1.
Changes
''-> "Auto (Learn)" entry, which removes the option sothat the kernel default (1, learn) applies
0,1and2, so that "Never" really writes0and existing
0/1/2values are always representable and preservedThe explicit
1entry is intentionally kept next to the automatic one: anabsent option is left untouched by netifd, while
option multicast_router '1'is re-applied on every reload. This mirrors the existingautonegoption (
automatic (enabled)+Enable).Tested manually on OpenWrt x86/64: selecting "Never" now writes
option multicast_router '0'(andbrport/multicast_routerreads0),while a previously set
0survives a save.