Skip to content

Commit

Permalink
hw-mgmt: scripts: Add missed asic thermal attributes for multi-asic s…
Browse files Browse the repository at this point in the history
…ystems

Add missed asic thermal attributes for multi-asic systems.
Added:

$tpath/asic{N}_temp_trip_crit
$tpath/asic{N}_temp_emergency
$tpath/asic{N}_temp_crit
$tpath/asic{N}_temp_norm

Signed-off-by: Oleksandr Shamray <[email protected]>
  • Loading branch information
sholeksandr committed Sep 25, 2024
1 parent cbf9099 commit a61471e
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions usr/usr/bin/hw-management-thermal-events.sh
Original file line number Diff line number Diff line change
Expand Up @@ -336,20 +336,28 @@ if [ "$1" == "add" ]; then
asic_index=${asic_indices[${asic_bus}]}
ln -fs "$3""$4" "$cpath"/asic${asic_index}_hwmon
check_n_link "$3""$4"/temp1_input "$tpath"/asic${asic_index}
check_n_init $tpath/asic${asic_index}_temp_trip_crit 120000
check_n_init $tpath/asic${asic_index}_temp_emergency 105000
check_n_init $tpath/asic${asic_index}_temp_crit 85000
check_n_init $tpath/asic${asic_index}_temp_norm 75000
if [ ${asic_index} -eq 1 ]; then
ln -fs "$3""$4" "$cpath"/asic_hwmon
check_n_link "$3""$4"/temp1_input "$tpath"/asic
check_n_init $tpath/asic_temp_trip_crit 120000
check_n_init $tpath/asic_temp_emergency 105000
check_n_init $tpath/asic_temp_crit 85000
check_n_init $tpath/asic_temp_norm 75000
fi
;;
*)
ln -fs "$3""$4" $cpath/asic_hwmon
check_n_link "$3""$4"/temp1_input "$tpath"/asic
check_n_init $tpath/asic_temp_trip_crit 120000
check_n_init $tpath/asic_temp_emergency 105000
check_n_init $tpath/asic_temp_crit 85000
check_n_init $tpath/asic_temp_norm 75000
;;
esac
echo 120000 > $tpath/asic_temp_trip_crit
echo 105000 > $tpath/asic_temp_emergency
echo 85000 > $tpath/asic_temp_crit
echo 75000 > $tpath/asic_temp_norm

if [ -f "$3""$4"/pwm1 ]; then
ln -sf "$3""$4"/pwm1 "$tpath"/pwm1
Expand Down

0 comments on commit a61471e

Please sign in to comment.