RDKCOM-5613: RDKBNETWOR-98 untagged vlan#40
Open
sherik-sensin wants to merge 2 commits into
Open
Conversation
Reason for change: CPE should be able to support IP connectivity(Static/PPPoE/IPoE) over native interface. Test Procedure: Performed VlanManager Sanity test. Risks: None. Signed-off-by: Sherik Sensin A <sherik.a@telekom-digital.com>
There was a problem hiding this comment.
Pull request overview
This PR adds special-case handling for VLAN entries using VLANId == -1 to represent a bridge-backed “untagged VLAN” by creating/deleting Linux bridges in the VLAN enable/disable paths.
Changes:
- In
Vlan_Enable(), create a bridge and add the base interface whenVLANId == -1. - In
Vlan_Disable(), bring down/delete the bridge and remove the base interface from it whenVLANId == -1.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+405
to
+413
| else if (pEntry->VLANId == -1) | ||
| { | ||
| /* If the VLANID = -1, the VLAN is a bridge, delete the bridge and delete the interface from the bridge */ | ||
| if(strcmp(pEntry->BaseInterface, pEntry->Name)) | ||
| { | ||
| v_secure_system("ifconfig %s down", pEntry->Name); | ||
| v_secure_system("brctl delif %s %s", pEntry->Name, pEntry->BaseInterface); | ||
| v_secure_system("brctl delbr %s", pEntry->Name); | ||
| } |
Comment on lines
+684
to
+686
| v_secure_system("brctl addbr %s", pEntry->Name); | ||
| v_secure_system("brctl addif %s %s", pEntry->Name, pEntry->BaseInterface); | ||
| v_secure_system("ifconfig %s up", pEntry->Name); |
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.
No description provided.