-
Notifications
You must be signed in to change notification settings - Fork 2k
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
cmds_gnrc_netif: Support enabling/disabling lwIP netifs from gnrc_netif shell #19972
Conversation
Similar to forcing interface up/down on Linux. In lwIP this is separate to link state.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good
bors merge |
Build succeeded! The publicly hosted instance of bors-ng is deprecated and will go away soon. If you want to self-host your own instance, instructions are here. If you want to switch to GitHub's built-in merge queue, visit their help page. |
Contribution description
Similar to Linux, lwIP has separate link and interface statuses.
This change expose this in a netopt and updates gnrc ifconfig to show and set it.
I am not really happy with the
NETOPT_ACTIVE
name. MaybeNETOPT_STATE
could be renamed toNETOPT_RF_STATE
?The code for setting up/down is not very nice. Not sure if link state will be controllable in lwIP - maybe for 6lowpan radios.
Testing procedure
Flash
tests/pkg/lwip
. Any traffic received while the interface is down is dropped.Issues/PRs references
This only makes a difference when gnrc_netif ifconfig command is used. For that it depends on #19971 and an extra change like 7160ed9 to replace lwip netif with the gnrc version.