From a5ac7f6b6928e3a280603470b1267206419b2033 Mon Sep 17 00:00:00 2001 From: Bob Chu <79439153+qnos@users.noreply.github.com> Date: Sun, 12 May 2024 16:45:19 +0800 Subject: [PATCH] [devices]: Seastone fix issue #18767 psu fan speed issue (#18787) Fix issue #18787 fan information could not been shown issue. How I did it Add psu fan get_target_speed api support. How to verify it Use `show platform fan` in branch 202311. --- device/celestica/x86_64-cel_seastone-r0/sonic_platform/fan.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/device/celestica/x86_64-cel_seastone-r0/sonic_platform/fan.py b/device/celestica/x86_64-cel_seastone-r0/sonic_platform/fan.py index 00785dd8fddf..9269dbe26fc2 100644 --- a/device/celestica/x86_64-cel_seastone-r0/sonic_platform/fan.py +++ b/device/celestica/x86_64-cel_seastone-r0/sonic_platform/fan.py @@ -188,6 +188,8 @@ def get_target_speed(self): sysfs_path = sysfs_path.format(fan_index[self.fan_tray_index]) pwm = self._api_helper.read_txt_file(sysfs_path) target = round(int(pwm) / 255 * 100.0) + else: + return self.get_speed() return target