Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix error msg due to not supported "SAI_SWITCH_ATTR_MAX_NUMBER_OF_TEM…
…P_SENSORS" attributes (sonic-net#1745) **What I did** 1. Add more conditions to capture SAI return code due to not supported SAI attributes. Original code only judge: `status == SAI_STATUS_NOT_SUPPORTED || status == SAI_STATUS_NOT_IMPLEMENTED` Add more conditions: `SAI_STATUS_IS_ATTR_NOT_SUPPORTED(status) || SAI_STATUS_IS_ATTR_NOT_IMPLEMENTED(status)` 2. Print the error code in hex instead of dec to make it more readable. **Why I did it** To eliminate below error msg on the platform which not support "SAI_SWITCH_ATTR_MAX_NUMBER_OF_TEMP_SENSORS" `May 10 13:02:59.806194 sonic ERR swss#orchagent: :- initSensorsTable: ASIC sensors : failed to get SAI_SWITCH_ATTR_MAX_NUMBER_OF_TEMP_SENSORS: -196608` **How I verified it** On the Mellanox platform, in the reboot process, the above error msg will not be observed.
- Loading branch information