Repository navigation
fix: preserve UCI radio identity on shared PHY devices - #42
Merged
Merged
Conversation
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.
Summary
Addresses #39, based on @flubba's detailed diagnosis and proposed UCI-section preservation. Please keep the issue open pending verification on the reporter's BE12 Pro; this PR intentionally does not auto-close it.
luci-rpc.getWirelessDevicesrather than deriving it from a shared PHY index.Cause and upstream research
OpenWrt can create distinct
wifi-devicesections for multiple radio indices on one PHY. Its mac80211 configuration generator, LuCI RPC implementation, and multi-radio design discussion support treating the UCI section key—notphyN—as the configuration identity.Previously both reported bands could render the same
oowrt_wlanN_radio0. The router could confirm that collapsed configuration before ownership recording failed on its unique key. This PR corrects the target and adds pre-write rejection rather than weakening the ownership constraint.Validation
go test ./internal/capability ./internal/render ./internal/reconcile -count=1— all passed after final review corrections, run outside the implementer's listener-restricted sandbox.go vet ./internal/capability ./internal/render ./internal/reconcile— passed.npm --prefix docs run build— passed, including all nine screenshot-validator tests and checks of 35 screenshots/48 documentation references.git diff --check, mock Python syntax validation, and independent final review — passed.GitHub CI passed on commit
b3b7adfec9549c901c72601f49bada8a1e96ec5e: full Go tests/vet/modules, race detector, UI tests/build/budget, release packaging, and secret scan. The Documentation workflow also passed build/validation; Pages deployment was correctly skipped for this PR. The PR does not publish a release or container image.No physical-router verification is claimed. The local lab Ethernet link is inactive, and its reference routers are not the reporter's MT7996 hardware. The shared-PHY tests use reproducible fixtures and mock router operations. No actual router or controller data was changed.
Verification on affected hardware
The review build is commit
b3b7adfec9549c901c72601f49bada8a1e96ec5e, not an official release. For a local container build from a new checkout:Building the image does not start it or touch controller data. Use your existing deployment's data directory and runtime passphrase only after taking the backup below; do not run two controllers against the same database.
oowrt_wlanN_radio0andoowrt_wlanN_radio1sections with the correspondingdevicereferences before authorizing Apply.The previous failed operation may already have changed the router. Do not reset the database, clear ownership records, or re-adopt to work around this error. Please report whether this exact PR build resolves the issue on the BE12 Pro; any remaining failure should include sanitized re-probe/preview output and the precise error, not credentials or wireless keys.