[portsorch] Expose supported FEC modes to STABE_DB and check whether FEC mode is supported before setting it#2400
Merged
prgeor merged 2 commits intosonic-net:masterfrom Aug 8, 2022
Conversation
Collaborator
Author
Collaborator
|
@prgeor , can you please sign-off/merge? |
keboliu
previously approved these changes
Jul 28, 2022
keboliu
previously approved these changes
Jul 29, 2022
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Collaborator
|
@prgeor , would you please sign-off/merge? |
prgeor
approved these changes
Aug 4, 2022
Contributor
|
@stephenxs 84a32e2 this commit doesnot seem right. lets discuss. |
Collaborator
Author
…d check whether FEC mode is supported before setting it (sonic-net#2333)" (sonic-net#2396)" This reverts commit 6565b50.
Signed-off-by: Stephen Sun <stephens@nvidia.com>
84a32e2 to
0767f27
Compare
Collaborator
Author
|
/easycla |
prgeor
approved these changes
Aug 8, 2022
Contributor
|
@stephenxs this PR cannot be cherry picked cleanly to 202205 branch. Please raise separate PR. |
7 tasks
yxieca
pushed a commit
that referenced
this pull request
Aug 11, 2022
…FEC mode is supported before setting it (#2400) * Revert "Revert "[portsorch] Expose supported FEC modes to STABE_DB and check whether FEC mode is supported before setting it (#2333)" (#2396)" This reverts commit 6565b50. * Adjust the prototype of setPortFec Signed-off-by: Stephen Sun <stephens@nvidia.com>
abdosi
added a commit
that referenced
this pull request
Aug 30, 2022
Why I did: PR: #2400 made change to pass <string> as argument to API setPortFecMode but did not updated the corresponding gbsyncd API call
yxieca
pushed a commit
that referenced
this pull request
Sep 1, 2022
Why I did: PR: #2400 made change to pass <string> as argument to API setPortFecMode but did not updated the corresponding gbsyncd API call
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
…FEC mode is supported before setting it (sonic-net#2400) * Revert "Revert "[portsorch] Expose supported FEC modes to STABE_DB and check whether FEC mode is supported before setting it (sonic-net#2333)" (sonic-net#2396)" This reverts commit 6565b50. * Adjust the prototype of setPortFec Signed-off-by: Stephen Sun <stephens@nvidia.com>
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
Why I did: PR: sonic-net#2400 made change to pass <string> as argument to API setPortFecMode but did not updated the corresponding gbsyncd API call
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.
This is to
What I did
Expose supported FEC modes to
STATE_DB.PORT_TABLE|<port>.supported_fecs.The orchagent calls
get_port_attributeto get attributeSAI_PORT_ATTR_SUPPORTED_FEC_MODEduring initialization and then records it into internal data.STATE_DB. Eg.rs,nonemeans onlyrsandnoneis supported on the port.supported_fecsbefore setting FEC mode on a port to theCONFIG_DBN/Awill be exposed toSTATE_DBget_port_attributereturnsNot implementedCONFIG_DB.Why I did it
It is not supported to set FEC mode on some platforms. To avoid error, we need to expose the supported FEC list.
How I verified it
Manually test and mock test.
Details if related