Skip to content

Commit

Permalink
Add a call to apply app0 config before DP INIT
Browse files Browse the repository at this point in the history
  • Loading branch information
noaOrMlnx committed Jun 4, 2024
1 parent 5bb903c commit 6245c0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions sonic-xcvrd/tests/test_xcvrd.py
Original file line number Diff line number Diff line change
Expand Up @@ -1297,6 +1297,7 @@ def test_CmisManagerTask_task_worker(self, mock_chassis, mock_get_status_tbl):
mock_xcvr_api = MagicMock()
mock_xcvr_api.set_datapath_deinit = MagicMock(return_value=True)
mock_xcvr_api.set_datapath_init = MagicMock(return_value=True)
mock_xcvr_api.apply_app0_configuration = MagicMock(return_value=True)
mock_xcvr_api.tx_disable_channel = MagicMock(return_value=True)
mock_xcvr_api.set_lpmode = MagicMock(return_value=True)
mock_xcvr_api.set_application = MagicMock(return_value=True)
Expand Down
4 changes: 4 additions & 0 deletions sonic-xcvrd/xcvrd/xcvrd.py
Original file line number Diff line number Diff line change
Expand Up @@ -1474,6 +1474,10 @@ def task_worker(self):
# D.2.2 Software Deinitialization
api.set_datapath_deinit(host_lanes_mask)

self.log_info("Applying App0 configuration for port {}".format(lport))
if not api.apply_app0_configuration():
self.log_notice("{}: Could not apply application 0 configurations")

# D.1.3 Software Configuration and Initialization
media_lanes_mask = self.port_dict[lport]['media_lanes_mask']
if not api.tx_disable_channel(media_lanes_mask, True):
Expand Down

0 comments on commit 6245c0d

Please sign in to comment.