[sonic_xcvr] Restore Abort advertisement in FW mgmt features - #722
Conversation
Signed-off-by: Pavan Kalyan Nakka <pnakka@microsoft.com>
|
/azp run |
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
|
Azure Pipelines: Successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Pull request overview
This PR restores the “Abort CMD102h supported” advertisement in the CMIS CDB firmware-management features info text returned by the public transceiver API, after a prior refactor moved feature collection into CdbFwHandler.get_fw_mgmt_features().
Changes:
- Decode and propagate the “abort supported” bit from the firmware management advertisement field through
CdbFwHandler.get_fw_mgmt_features(). - Re-add
Abort CMD102h supported <bool>to theget_module_fw_mgmt_feature()returnedinfotext. - Update unit tests to reflect the updated
get_fw_mgmt_features()tuple shape.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/sonic_xcvr/test_cmis.py | Updates mocked firmware-feature tuples to include abort support bit. |
| tests/sonic_xcvr/test_cdb_fw.py | Updates expected get_fw_mgmt_features() return tuple to include abort support. |
| sonic_platform_base/sonic_xcvr/mem_maps/public/cmis/pages/page9f_cdb.py | Ensures firmware-mgmt advertisement field decodes into per-bit values (bitdecode=True). |
| sonic_platform_base/sonic_xcvr/cdb/cdb_fw.py | Captures abort support bit and returns it via get_fw_mgmt_features(). |
| sonic_platform_base/sonic_xcvr/api/public/cdb_fw.py | Restores abort support advertisement line in returned info text. |
| mgmt_features_adv = reply.get(cdb_consts.CDB_FIRMWARE_MGMT_ADV, {}) | ||
| self.start_payload_size = reply[cdb_consts.CDB_START_CMD_PAYLOAD_SIZE] | ||
| self.is_lpl_only = reply[cdb_consts.CDB_WRITE_MECHANISM] == "LPL" | ||
| self.rw_length_ext = reply[cdb_consts.CDB_READ_WRITE_LENGTH_EXT] + 8 |
|
This PR has backport request label(s) for branch(es): 202605, but is missing required test information. Please make sure you tick the tested branch(es) in the Tested branch section and provide test evidence (e.g., 202605: <test result>) in the Test result section as well in your PR description. ---Powered by SONiC BuildBot
|
|
@pnakka28 — This PR is requested for the 202605 branch but is missing test evidence. To move forward with cherry-pick approval, please:
Also, to help us prioritize correctly, could you clarify: Is this PR a bug fix / regression fix, a new feature, a platform config change, or a dependency/infra update? Understanding the nature of the change helps us triage the cherry-pick queue. Thank you! Review by @vaibhavhd via automated tooling |
This is a regression fix. A previous refactor dropped the existing "Abort CMD102h supported" advertisement from the returned info text. This PR restores that behavior. I tested the change against the 202605 branch and updated the PR description with the image version and test results. Note: This PR needs to be cherry picked after #681 is merged into 202605. The conflict label is due to this. |
|
The change is not in 202605 yet. @pnakka28, please manually create the cherry pick PR for branch 202605. ---Powered by SONiC BuildBot
|
Description
Restore the "Abort CMD102h supported" advertisement in the CDB firmware management features return text.
When
get_module_fw_mgmt_feature()was refactored to route all firmware-management features throughCdbFwHandler.get_fw_mgmt_features(). This dropped theAbort CMD102h supportedline that the previous implementation emitted, and the abort advertisement was not captured in return text.Changes:
cdb/cdb_fw.py: captureis_abort_supportedfrom the reply and include it inget_fw_mgmt_features().Abort CMD102h supported <bool>in theinfotext.test_cdb_fw.pyandtest_cmis.pybased on the changes.Motivation and Context
How Has This Been Tested?
test_cdb_fw.pyandtest_cmis.pypassed -> 484 passedget_module_fw_mgmt_feature()API now reportsAbort CMD102h supported <bool>.Additional Information (Optional)