Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Mellanox] Enhance is_module_host_management_mode to also check syncd…
…'s sai.profile (sonic-net#19261) - Why I did it Two steps (among others) are required to enable the host CMIS management feature: enabling it in the switch's sai.profile and performing a config reload. During the timeframe between these two steps, the control sysfs might be accessed, but they will not be present on the system until the latter step, the config reload, is completed. The code should try to access the control sysfs only after the config reload step. A good indication that this has been done is to check if the relevant entry is included in syncd's sai.profile. In contrast to the switch's sai.profile, syncd's sai.profile is only updated with the Host CMIS management support flag after the reload is complete. - How I did it I updated the is_module_host_management_mode() implementation to first look for the Host CMIS management support flag in syncd's sai.profile, and only if it does not exist for some reason, look for it in the switch's sai.profile. - How to verify it Add the Host CMIS management support flag to the switch's sai.profile and verify that the following log does not appear: ERR pmon#xcvrd: Exception occured at DomInfoUpdateTask thread due to Exception('control sysfs for SFP 20 does not exist')
- Loading branch information