[Mellanox] Initialize PSU API on both host and docker side (#7075)
- Why I did it There was a change to replace platform utils with sonic platform API in psuutil. However, psu API is not initialized on host side. The PR is to fix it. Backport of #7016 to the 202012 branch. - How I did it Initialize PSU API on both host and non-host side - How to verify it Manual test
This commit is contained in:
parent
740dd03138
commit
d79a456a62
@ -16,16 +16,14 @@ except ImportError as e:
|
||||
class Platform(PlatformBase):
|
||||
def __init__(self):
|
||||
PlatformBase.__init__(self)
|
||||
if self._is_host():
|
||||
self._chassis = Chassis()
|
||||
self._chassis.initialize_components()
|
||||
self._chassis.initizalize_system_led()
|
||||
self._chassis.initialize_eeprom()
|
||||
else:
|
||||
self._chassis = Chassis()
|
||||
self._chassis.initialize_psu()
|
||||
self._chassis.initialize_fan()
|
||||
self._chassis.initialize_eeprom()
|
||||
if self._is_host():
|
||||
self._chassis.initialize_components()
|
||||
self._chassis.initizalize_system_led()
|
||||
else:
|
||||
self._chassis.initialize_fan()
|
||||
self._chassis.initialize_thermals()
|
||||
|
||||
def _is_host(self):
|
||||
|
Reference in New Issue
Block a user