From 580b3284c4e0c6360438f61b5e1fa4ad4bd60cf3 Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Tue, 16 Jul 2024 08:06:48 +0000 Subject: [PATCH] hw-mgmt: thermal: Set PSU fan dir to "Unknown" if PSU FRU is broken Set PSU fan dir value to "Unknown" (value 2) if PSU FRU is broken Signed-off-by: Oleksandr Shamray --- usr/usr/bin/hw-management-thermal-events.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/usr/usr/bin/hw-management-thermal-events.sh b/usr/usr/bin/hw-management-thermal-events.sh index d54669fc3..0f85f3daa 100755 --- a/usr/usr/bin/hw-management-thermal-events.sh +++ b/usr/usr/bin/hw-management-thermal-events.sh @@ -962,6 +962,8 @@ if [ "$1" == "add" ]; then exit 0 fi echo "Failed to read PSU VPD" > $eeprom_path/"$psu_name"_vpd + # Set "Unknown fan dir in case failed to read PSU VPD. + echo 2 > "$thermal_path"/"$psu_name"_fan_dir exit 0 else # Add PSU FAN speed info.