-
Notifications
You must be signed in to change notification settings - Fork 543
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
[gearbox] Support setting tx taps on gearbox ports #2158
Conversation
@byu343 do ensure that during warm-reboot we are not setting these taps because it can cause the port to flap? |
@byu343 is this "system_tx_fir_pre2": [1,1]" format captured in HLD? can you point me the HLD? |
@Pterosaur @jimmyzhai please review |
No, this is no captured by HLD. I followed the existing format for system_lanes, such as: "system_lanes": [6,7]. And each value in system_tx_fir_pre2 matches the corresponding lane. |
@byu343 could you fix the merge conflicts? |
Done |
Reopen it |
Tagging @arlakshm for awareness |
For the credo gearbox phys, I think warm-reboot support is not considered for now. |
/Azp run Azure.sonic-swss |
Azure Pipelines successfully started running 1 pipeline(s). |
@Pterosaur @jimmyzhai Could please help to review this? Thanks. |
01fc353
to
ad1d17b
Compare
@anamehra: Please tag Shyam/Arpit. |
|
Couple of questions on this:
Regards, |
Hi Arpit, whether to provide those values in gearbox_config.json for any platform is optional. If orchagent finds the values from the gearbox_config.json, it will calls SAI implementation with the values; if it cannot, there is no calls to SAI for setting the tuning/tap values, so the tuning/tap support is not mandatory for the phy driver. |
Why I did it For the change to support gearbox taps by gearbox_config.json (sonic-net/sonic-swss#2158), I need to add tests to sonic-swss/tests/test_gearbox.py to satisfy the test coverage of the change. The existing code in test_gearbox.py has already used brcm_gearbox_vs and here is to add some gearbox tap value to its gearbox_config.json, for the added tests in sonic-swss/tests/test_gearbox.py. How I did it How to verify it This change itself will not affect existing code.
/Azp run Azure.sonic-swss |
Azure Pipelines successfully started running 1 pipeline(s). |
/Azp run Azure.sonic-swss |
Commenter does not have sufficient privileges for PR 2158 in repo sonic-net/sonic-swss |
/Azpw run Azure.sonic-swss |
/AzurePipelines run Azure.sonic-swss |
Azure Pipelines successfully started running 1 pipeline(s). |
Hi @jimmyzhai @arpp93 @prgeor, could you please review this again? Thanks. |
What I did This change adds support for setting tx tap or tuning values on gearbox ports. It uses the SAI attributes such as SAI_PORT_SERDES_ATTR_TX_FIR_PRE1 to communicate with SAI-based gearbox drivers. For the values, they are provided in the format like "system_tx_fir_pre2": [1,1] for an interface from gearbox_config.json. Why I did it How I verified it We verified that values provided in sonic-net/sonic-buildimage#10084 are set to the chip with this change. Added test to tests/test_gearbox.py. The added test will not pass until the following two changes (which should be merged first) are merged: Support SAI_PORT_ATTR_PORT_SERDES_ID on vs gearbox: sonic-net/sonic-sairedis#1082 Add gearbox taps to vs gearbox_config.json: sonic-net/sonic-buildimage#11480 Updated handling of VRF_VNI mapping and VLAN_VNI mapping for same VNI ID fixed compile issues Updated code for the flow where VRF VNI mapping is processed first followed by VLAN VNI mapping
Why I did it This change specifies the tuning values for each lane of the B52 phy chips. These values can be different for different ports. The values being set are under the assumption of optical transceivers. This change depends on the change to sonic-swss: sonic-net/sonic-swss#2158. How to verify it We verified the values are correctly set on the B52 chips of Arista 7280cr3, by reading them from the debug cli of the B52 driver.
What I did
This change adds support for setting tx tap or tuning values on gearbox ports. It uses the SAI attributes such as SAI_PORT_SERDES_ATTR_TX_FIR_PRE1 to communicate with SAI-based gearbox drivers. For the values, they are provided in the format like "system_tx_fir_pre2": [1,1] for an interface from gearbox_config.json.
Why I did it
How I verified it
We verified that values provided in sonic-net/sonic-buildimage#10084 are set to the chip with this change.
Added test to tests/test_gearbox.py. The added test will not pass until the following two changes (which should be merged first) are merged:
Support SAI_PORT_ATTR_PORT_SERDES_ID on vs gearbox: sonic-net/sonic-sairedis#1082
Add gearbox taps to vs gearbox_config.json: sonic-net/sonic-buildimage#11480
Details if related