-
Notifications
You must be signed in to change notification settings - Fork 305
Description
Background
According to O-RAN specifications, the VLAN PCP field should be configurable to support QoS differentiation. However, the current implementation effectively forces PCP to 0.
Current Issue
The vlan_tag_cp and vlan_tag_up parameters are validated with CLI::Range(1, 4094), which only allows VID values. This prevents users from setting PCP bits in the TCI field.
Current validation
cppadd_option(app, "--vlan_tag_cp", config.vlan_tag_cp, "C-Plane V-LAN identifier")
->capture_default_str()
->check(CLI::Range(1, 4094)); // Only VID range
TCI structure (IEEE 802.1Q):
[PCP: 3 bits][DEI: 1 bit][VID: 12 bits]
Proposed Solutions
Solution 1: Extend validation range to full TCI
Change the validation range from 1-4094 (VID only) to 1-65535 (full TCI), allowing users to specify PCP in the upper 3 bits.
Example configuration:
yamlru_ofh:
cells:
- vlan_tag_cp: 0xC003 # PCP=6, VID=3
vlan_tag_up: 0xA003 # PCP=5, VID=3
Pros:
Minimal code change (only validation range)
No new configuration parameters
Supports all TCI fields (PCP, DEI, VID)
Cons:
Requires users to calculate hexadecimal TCI values
Less intuitive configuration
Solution 2: Add dedicated PCP parameters
Add new configuration parameters vlan_pcp_cp and vlan_pcp_up (range 0-7).
Example configuration:
yamlru_ofh:
cells:
- vlan_tag_cp: 3
vlan_tag_up: 3
vlan_pcp_cp: 6 # C-Plane priority
vlan_pcp_up: 5 # U-Plane priority
Pros:
More intuitive and user-friendly
Clear separation of VID and PCP
Self-documenting configuration
Cons:
Requires more code changes
Adds new configuration parameters
Question
Which solution is preferred for this project? Or is there a better approach?