Skip to content
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

[CMIS] 'get_transceiver_info' should return 'None' when CMIS cable EEPROM is not ready #305

Merged
merged 2 commits into from
Sep 2, 2022

Conversation

keboliu
Copy link
Collaborator

@keboliu keboliu commented Aug 31, 2022

Signed-off-by: Kebo Liu kebol@nvidia.com

Description

When the CMIS cable EEPROM is not ready, get_transceiver_info should return None to notify XCVRD that cable EEPROM is not ready instead of returning a dictionary including 'None' values.

If any field is 'None', we consider the CMIS cable EEPROM is not fully ready yet.

Motivation and Context

get_transceiver_info should return a dictionary including the correct field and values to XCVRD, if EEPROM is not ready should not return a dictionary with incorrect values. The 'None' return value can trigger XCVRD to start the retry EEPROM reading flow.

This is also to fix issue sonic-net/sonic-buildimage#11525

How Has This Been Tested?

keep run sfputil reset test case and see no further crash.

Additional Information (Optional)

… ready

Signed-off-by: Kebo Liu <kebol@nvidia.com>
Signed-off-by: Kebo Liu <kebol@nvidia.com>
@prgeor prgeor merged commit 75c055e into sonic-net:master Sep 2, 2022
dprital added a commit to dprital/sonic-buildimage that referenced this pull request Sep 4, 2022
Update sonic-platform-common submodule pointer to include the following:
* [CMIS] 'get_transceiver_info' should return 'None' when CMIS cable EEPROM is not ready  ([sonic-net#305](sonic-net/sonic-platform-common#305))
* uplift code coverage 80% ([sonic-net#307](sonic-net/sonic-platform-common#307))
* [sonic-pcie] Add UT for pcie_common.py ([sonic-net#293](sonic-net/sonic-platform-common#293))
* [CMIS] Catch Exception to avoid CMIS code crash ([sonic-net#299](sonic-net/sonic-platform-common#299))
* [Credo][Ycable] fix incorrect uart statistics ([sonic-net#296](sonic-net/sonic-platform-common#296))
* Add PSU input voltage and input current ([sonic-net#295](sonic-net/sonic-platform-common#295))

Signed-off-by: dprital <drorp@nvidia.com>
yxieca pushed a commit that referenced this pull request Sep 8, 2022
…PROM is not ready (#305)

* get_transceiver_info should return None when cmis cable eeprom is not ready

Signed-off-by: Kebo Liu <kebol@nvidia.com>

* Add more comments to describe the change

Signed-off-by: Kebo Liu <kebol@nvidia.com>

Signed-off-by: Kebo Liu <kebol@nvidia.com>
@keboliu keboliu deleted the cmis_enhance branch September 10, 2022 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants