-
Notifications
You must be signed in to change notification settings - Fork 680
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
CLI to skip polling for periodic information for a port in DomInfoUpdateTask thread #3187
Merged
Conversation
This file contains 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
…ateTask thread Signed-off-by: Mihir Patel <patelmi@microsoft.com>
9701948
to
6c6baac
Compare
…into dom_config_cli
@mihirpat1 can you explain "Why I did this" too in the PR description |
@prgeor I have added this section now. |
prgeor
reviewed
Mar 7, 2024
prgeor
previously approved these changes
Mar 7, 2024
prgeor
approved these changes
Mar 7, 2024
@StormLiangMS @yxieca - Can you please help with cherry-pick to 202305 and 202311? |
mssonicbld
pushed a commit
to mssonicbld/sonic-utilities
that referenced
this pull request
Mar 8, 2024
…ateTask thread (sonic-net#3187) * CLI to skip polling for periodic infomration for a port in DomInfoUpdateTask thread Signed-off-by: Mihir Patel <patelmi@microsoft.com> * Fixed unit-test failure * Modified dom_status to dom_polling * Modified comment for failing the command --------- Signed-off-by: Mihir Patel <patelmi@microsoft.com>
Cherry-pick PR to 202311: #3200 |
mssonicbld
pushed a commit
that referenced
this pull request
Mar 8, 2024
…ateTask thread (#3187) * CLI to skip polling for periodic infomration for a port in DomInfoUpdateTask thread Signed-off-by: Mihir Patel <patelmi@microsoft.com> * Fixed unit-test failure * Modified dom_status to dom_polling * Modified comment for failing the command --------- Signed-off-by: Mihir Patel <patelmi@microsoft.com>
hi @mihirpat1 could you run test with 202305 image with this PR? |
qiluo-msft
pushed a commit
to sonic-net/sonic-buildimage
that referenced
this pull request
Mar 11, 2024
…18277) ### Why I did it Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. ### How I did it Added `dom_polling` field to CONFIG_DB PORT table. #### How to verify it Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
mssonicbld
pushed a commit
to mssonicbld/sonic-utilities
that referenced
this pull request
Mar 12, 2024
…ateTask thread (sonic-net#3187) * CLI to skip polling for periodic infomration for a port in DomInfoUpdateTask thread Signed-off-by: Mihir Patel <patelmi@microsoft.com> * Fixed unit-test failure * Modified dom_status to dom_polling * Modified comment for failing the command --------- Signed-off-by: Mihir Patel <patelmi@microsoft.com>
Cherry-pick PR to 202305: #3211 |
mssonicbld
pushed a commit
that referenced
this pull request
Mar 12, 2024
…ateTask thread (#3187) * CLI to skip polling for periodic infomration for a port in DomInfoUpdateTask thread Signed-off-by: Mihir Patel <patelmi@microsoft.com> * Fixed unit-test failure * Modified dom_status to dom_polling * Modified comment for failing the command --------- Signed-off-by: Mihir Patel <patelmi@microsoft.com>
saksarav-nokia
pushed a commit
to saksarav-nokia/sonic-buildimage
that referenced
this pull request
Mar 12, 2024
…onic-net#18277) ### Why I did it Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. ### How I did it Added `dom_polling` field to CONFIG_DB PORT table. #### How to verify it Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
mihirpat1
added a commit
to mihirpat1/sonic-buildimage
that referenced
this pull request
Mar 12, 2024
…onic-net#18277) Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. Added `dom_polling` field to CONFIG_DB PORT table. Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
11 tasks
mihirpat1
added a commit
to mihirpat1/sonic-buildimage
that referenced
this pull request
Mar 12, 2024
…onic-net#18277) Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. Added `dom_polling` field to CONFIG_DB PORT table. Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
11 tasks
StormLiangMS
pushed a commit
to sonic-net/sonic-buildimage
that referenced
this pull request
Mar 18, 2024
…18277) (#18343) Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. Added `dom_polling` field to CONFIG_DB PORT table. Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
yxieca
pushed a commit
to sonic-net/sonic-buildimage
that referenced
this pull request
Mar 21, 2024
…18277) (#18344) Added YANG related changes for adding `dom_polling` field in PORT table of CONFIG_DB. This field can be set with `config interface transceiver dom PORT_NAME (enable|disable)` CLI. The `dom_polling` field was added through sonic-net/sonic-utilities#3187. Please refer to this PR for the details on the reason for adding `dom_polling` field. Added `dom_polling` field to CONFIG_DB PORT table. Added unit tests for both valid and invalid options for controlling `dom_polling`. Valid values for for `dom_polling` are `enabled` and `disabled` Any other value is treated as an invalid value
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.
MSFT ADO - 26801913
What I did
Created a CLI to enable/disable periodic polling through DomInfoUpdateTask thread in XCVRD.
The CLI handler related code changes in xcvrd can be found at sonic-net/sonic-platform-daemons#443
Why I did this
With sonic-net/sonic-platform-daemons#443, the DomInfoUpdateTask thread in xcvrd now polls periodically for reading CDB firmware version of transceiver to update the TRANSCEIVER_FIRMWARE_INFO table.
However, transceivers cannot handle multiple CDB commands issued from different sources at the same time.
This scenario is likely to occur during CDB firmware upgrade (triggered through
sfputil firmware download/run/commit
) and while issuingsfputil show fwversion PORT_NAME
CLI wherein 1 or more CDB commands are issued to the transceiver. At the same time, the DomInfoUpdateTask thread can issue a CDB command to read the firmware version as part of its periodic polling.Hence, in order to ensure that only one process accesses the CDB command feature on transceivers at a time, the
config interface transceiver dom PORT_NAME enable/disable
CLI has been created to allow user to disable background polling of DomInfoUpdateTask thread for the particular port before upgrading the CDB firmware or before issuingsfputil show fwversion PORT_NAME
CLI.How I did it
With the execution of
config interface transceiver dom PORT_NAME enable/disable
CLI, thedom_polling
field in PORT table of CONFIG_DB will be modified with the below valueconfig interface transceiver dom PORT_NAME enable
CLI, thedom_polling
field will be set toenabled
config interface transceiver dom PORT_NAME disable
CLI, thedom_polling
field will be set todisabled
For breakout ports, this CLI should always be executed for the first subport (subport = 1) of a breakout port group (even though, CDB access is required for subport > 1 ).
How to verify it
Please refer to the test details attached to sonic-net/sonic-platform-daemons#443
Previous command output (if the output of a command-line utility has changed)
New command output (if the output of a command-line utility has changed)