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

Add high power class support for non-CMIS modules in xcvrd #574

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

longhuan-cisco
Copy link
Contributor

Description

  1. Add xcvrd/sff_mgr support for enabling high power class if module's power class is greater or equal to 5 (Refer to SFF-8636 spec 6.2.6 Control Functions (Page 00h, Bytes 86-99) for byte 93 definition)

  2. Change enable_sff_mgr flag to enable_sff_mgr_controlled_tx, so that sff_mgr will always get spawned by default, and all platforms/vendors by default can get the benefit of high power class enabling/etc. Only sff_mgr's controlling on module Tx is platform based (enable_sff_mgr_controlled_tx)

Motivation and Context

Without enabling high power class for those modules, the module won't operate properly with power output and link won't come up.

How Has This Been Tested?

Verified the module operate with proper power output.

Additional Information (Optional)

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

if power_class < 5:
# No action needed for power class < 5
return

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@prgeor
Continue the discussion of sonic-net/sonic-platform-common#521 (comment) here at sff_mgr PR, regarding whether setting power_override bit should be included as part of handle_high_power_class:

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high power class enabling (added by this PR) and lpmode turning-off are two different independent steps. Not all modules need high power class enabling(only for power_class>=5), while most of the optical modules need lpmode turning-off.

Today, power_override bit setting has already been done by sff_mgr's lpmode turning-off (as part of which, xcvr API set_lpmode() gets called setting power_override bit). There's no need to do extra setting for that bit as part of high power class enabling.

image
Also from functionality POV, would it make more sense to decouple power_override bit from handling of high_power_class? Because, according to the truth table 6-11, once high power class (byte 93 bit 2 or/and bit 3) gets set properly, the module will function in the desired power class after the module is brought out of lpmode by either HW control or SW control.

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants