-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate frequency band suffix options to uci sections for each band. #896
Migrate frequency band suffix options to uci sections for each band. #896
Conversation
Codecov Report
@@ Coverage Diff @@
## master #896 +/- ##
==========================================
+ Coverage 74.51% 74.66% +0.15%
==========================================
Files 42 43 +1
Lines 3629 3659 +30
==========================================
+ Hits 2704 2732 +28
- Misses 925 927 +2
Continue to review full report at Codecov.
|
I agree with the change, I was bothered with supporting the frequency suffix there in the first place, as I think that at that point of customization a specific section would be the way to go. Is the commit "mesh-blocker: add-package" 4e0b122 intentionally mixed into this PR? |
I have no opinion at all on the proposal (since I haven't been following development) but regarding this:
just wanted to point out, this is not always the case. I remember using dualband radios where the same radio has both frequency bands (they can't be used concurrently). I remember one USB dongle that worked like this. |
9e9a748
to
40a56e9
Compare
It was added by mistake, I've removed it from the PR :) |
Oh, I didn't know, that's curious.. I'd say that we can go forward with this config schema and address the support for these kind of radios in the future if anyone claim the need for it. |
Wow, outstanding work @germanferrero !! Contrats!! |
While working on a service that would expose ubus enpoints for changing AP settings (such as disabling ap mode), I found out that it is really difficult to work with
list mode
option when thefrequency suffix
is used.A lot of thinking and code is needed to unpack the configuration scenario, handle all corner cases and pack it again when doing some change programmatically (or even manually).
This PR proposal is to migrate from configs like these:
To
In this way, disabling ap mode from 2ghz requires only to remove ap mode from
2ghz.modes
listOtherwise we need to think of replacing 'ap' with 'ap_5ghz' in
wifi.modes
to avoid modifying 5ghz radios behavior too.The code for wireless.configure gets simplified aswell.
Now all options for a radio would be taken from three levels, in order of precedence: radio (config wifi), band (config lime-wifi-band), general (config lime wifi).
A migration script is added as a uci-default so lime-community and lime-node configurations out there are transformed to the new syntaxis before running lime-config on first boot.
There is a test for the migration script as well, and I've done manual testing too. But please review it carefully.
Breaking changes
Details:
lime.wifi.modes
support is kept to avoid duplication of modes when no differentiation between bands is needed.