From bf556c5cd72b328692403756d35972a28211ad39 Mon Sep 17 00:00:00 2001 From: Yuanzhe <150663541+yuazhe@users.noreply.github.com> Date: Tue, 21 May 2024 13:52:33 +0800 Subject: [PATCH] [Mellanox] Fix 4600c sensors.conf inverted psu number designation (#18722) - Why I did it This PR is used to standardize several sensors.conf psu section I. Fix 4600/4600c inverted psu number designation II. Fix 5600 second psu miss set_power_cap label III. Standardized comments - How to verify it check sensors command output Signed-off-by: Yuanzhe, Liu --- .../x86_64-mlnx_msn2010-r0/sensors.conf | 2 +- .../x86_64-mlnx_msn4600-r0/sensors.conf | 28 +++++++-------- .../x86_64-mlnx_msn4600c-r0/sensors.conf | 34 +++++++++---------- .../sensors_respin.conf | 34 +++++++++---------- .../x86_64-nvidia_sn2201-r0/sensors.conf | 2 +- .../x86_64-nvidia_sn5600-r0/sensors.conf | 1 + 6 files changed, 51 insertions(+), 50 deletions(-) diff --git a/device/mellanox/x86_64-mlnx_msn2010-r0/sensors.conf b/device/mellanox/x86_64-mlnx_msn2010-r0/sensors.conf index 9bcfcbe21138..92d742c18453 100644 --- a/device/mellanox/x86_64-mlnx_msn2010-r0/sensors.conf +++ b/device/mellanox/x86_64-mlnx_msn2010-r0/sensors.conf @@ -15,7 +15,7 @@ bus "i2c-7" "i2c-1-mux (chan_id 6)" chip "lm75-i2c-*-4b" label temp1 "Ambient Fan Side Temp (air intake)" -# Power supplies +# Power controllers bus "i2c-5" "i2c-1-mux (chan_id 4)" chip "tps53679-i2c-*-70" label in1 "PMIC-1 PSU 12V Rail (in1)" diff --git a/device/mellanox/x86_64-mlnx_msn4600-r0/sensors.conf b/device/mellanox/x86_64-mlnx_msn4600-r0/sensors.conf index 8443e1b11c82..4c374a839be9 100644 --- a/device/mellanox/x86_64-mlnx_msn4600-r0/sensors.conf +++ b/device/mellanox/x86_64-mlnx_msn4600-r0/sensors.conf @@ -162,20 +162,6 @@ bus "i2c-15" "i2c-1-mux (chan_id 6)" # Power supplies bus "i2c-4" "i2c-1-mux (chan_id 3)" chip "dps460-i2c-*-58" - label in1 "PSU-1(L) 220V Rail (in)" - ignore in2 - label in3 "PSU-1(L) 12V Rail (out)" - label fan1 "PSU-1(L) Fan 1" - ignore fan2 - ignore fan3 - label temp1 "PSU-1(L) Temp 1" - label temp2 "PSU-1(L) Temp 2" - label temp3 "PSU-1(L) Temp 3" - label power1 "PSU-1(L) 220V Rail Pwr (in)" - label power2 "PSU-1(L) 12V Rail Pwr (out)" - label curr1 "PSU-1(L) 220V Rail Curr (in)" - label curr2 "PSU-1(L) 12V Rail Curr (out)" - chip "dps460-i2c-*-59" label in1 "PSU-2(R) 220V Rail (in)" ignore in2 label in3 "PSU-2(R) 12V Rail (out)" @@ -189,6 +175,20 @@ bus "i2c-4" "i2c-1-mux (chan_id 3)" label power2 "PSU-2(R) 12V Rail Pwr (out)" label curr1 "PSU-2(R) 220V Rail Curr (in)" label curr2 "PSU-2(R) 12V Rail Curr (out)" + chip "dps460-i2c-*-59" + label in1 "PSU-1(L) 220V Rail (in)" + ignore in2 + label in3 "PSU-1(L) 12V Rail (out)" + label fan1 "PSU-1(L) Fan 1" + ignore fan2 + ignore fan3 + label temp1 "PSU-1(L) Temp 1" + label temp2 "PSU-1(L) Temp 2" + label temp3 "PSU-1(L) Temp 3" + label power1 "PSU-1(L) 220V Rail Pwr (in)" + label power2 "PSU-1(L) 12V Rail Pwr (out)" + label curr1 "PSU-1(L) 220V Rail Curr (in)" + label curr2 "PSU-1(L) 12V Rail Curr (out)" # Chassis fans chip "mlxreg_fan-isa-*" diff --git a/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors.conf b/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors.conf index 02f811b6c795..4f60ceb02167 100644 --- a/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors.conf +++ b/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors.conf @@ -220,23 +220,6 @@ bus "i2c-15" "i2c-1-mux (chan_id 6)" # Power supplies bus "i2c-4" "i2c-1-mux (chan_id 3)" chip "dps460-i2c-*-58" - label in1 "PSU-1(L) 220V Rail (in)" - ignore in2 - label in3 "PSU-1(L) 12V Rail (out)" - label fan1 "PSU-1(L) Fan 1" - ignore fan2 - ignore fan3 - label temp1 "PSU-1(L) Temp 1" - label temp2 "PSU-1(L) Temp 2" - label temp3 "PSU-1(L) Temp 3" - label power1 "PSU-1(L) 220V Rail Pwr (in)" - label power2 "PSU-1(L) 12V Rail Pwr (out)" - label curr1 "PSU-1(L) 220V Rail Curr (in)" - label curr2 "PSU-1(L) 12V Rail Curr (out)" - set in3_lcrit in3_crit * 0.662 - set in3_min in3_crit * 0.745 - set in3_max in3_crit * 0.952 - chip "dps460-i2c-*-59" label in1 "PSU-2(R) 220V Rail (in)" ignore in2 label in3 "PSU-2(R) 12V Rail (out)" @@ -253,6 +236,23 @@ bus "i2c-4" "i2c-1-mux (chan_id 3)" set in3_lcrit in3_crit * 0.662 set in3_min in3_crit * 0.745 set in3_max in3_crit * 0.952 + chip "dps460-i2c-*-59" + label in1 "PSU-1(L) 220V Rail (in)" + ignore in2 + label in3 "PSU-1(L) 12V Rail (out)" + label fan1 "PSU-1(L) Fan 1" + ignore fan2 + ignore fan3 + label temp1 "PSU-1(L) Temp 1" + label temp2 "PSU-1(L) Temp 2" + label temp3 "PSU-1(L) Temp 3" + label power1 "PSU-1(L) 220V Rail Pwr (in)" + label power2 "PSU-1(L) 12V Rail Pwr (out)" + label curr1 "PSU-1(L) 220V Rail Curr (in)" + label curr2 "PSU-1(L) 12V Rail Curr (out)" + set in3_lcrit in3_crit * 0.662 + set in3_min in3_crit * 0.745 + set in3_max in3_crit * 0.952 # Chassis fans chip "mlxreg_fan-isa-*" diff --git a/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors_respin.conf b/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors_respin.conf index 4cf7b71ef80b..0e346b31e28f 100644 --- a/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors_respin.conf +++ b/device/mellanox/x86_64-mlnx_msn4600c-r0/sensors_respin.conf @@ -255,23 +255,6 @@ bus "i2c-15" "i2c-1-mux (chan_id 6)" # Power supplies bus "i2c-4" "i2c-1-mux (chan_id 3)" chip "dps460-i2c-*-58" - label in1 "PSU-1(L) 220V Rail (in)" - ignore in2 - label in3 "PSU-1(L) 12V Rail (out)" - label fan1 "PSU-1(L) Fan 1" - ignore fan2 - ignore fan3 - label temp1 "PSU-1(L) Temp 1" - label temp2 "PSU-1(L) Temp 2" - label temp3 "PSU-1(L) Temp 3" - label power1 "PSU-1(L) 220V Rail Pwr (in)" - label power2 "PSU-1(L) 12V Rail Pwr (out)" - label curr1 "PSU-1(L) 220V Rail Curr (in)" - label curr2 "PSU-1(L) 12V Rail Curr (out)" - set in3_lcrit in3_crit * 0.662 - set in3_min in3_crit * 0.745 - set in3_max in3_crit * 0.952 - chip "dps460-i2c-*-59" label in1 "PSU-2(R) 220V Rail (in)" ignore in2 label in3 "PSU-2(R) 12V Rail (out)" @@ -288,6 +271,23 @@ bus "i2c-4" "i2c-1-mux (chan_id 3)" set in3_lcrit in3_crit * 0.662 set in3_min in3_crit * 0.745 set in3_max in3_crit * 0.952 + chip "dps460-i2c-*-59" + label in1 "PSU-1(L) 220V Rail (in)" + ignore in2 + label in3 "PSU-1(L) 12V Rail (out)" + label fan1 "PSU-1(L) Fan 1" + ignore fan2 + ignore fan3 + label temp1 "PSU-1(L) Temp 1" + label temp2 "PSU-1(L) Temp 2" + label temp3 "PSU-1(L) Temp 3" + label power1 "PSU-1(L) 220V Rail Pwr (in)" + label power2 "PSU-1(L) 12V Rail Pwr (out)" + label curr1 "PSU-1(L) 220V Rail Curr (in)" + label curr2 "PSU-1(L) 12V Rail Curr (out)" + set in3_lcrit in3_crit * 0.662 + set in3_min in3_crit * 0.745 + set in3_max in3_crit * 0.952 # Chassis fans chip "mlxreg_fan-isa-*" diff --git a/device/mellanox/x86_64-nvidia_sn2201-r0/sensors.conf b/device/mellanox/x86_64-nvidia_sn2201-r0/sensors.conf index 908ebe7c1ccd..5024abd70017 100644 --- a/device/mellanox/x86_64-nvidia_sn2201-r0/sensors.conf +++ b/device/mellanox/x86_64-nvidia_sn2201-r0/sensors.conf @@ -130,7 +130,7 @@ bus "i2c-8" "i2c-1-mux (chan_id 6)" label in8 "MONITOR CPU Board V1P8" label in9 "MONITOR CPU Board V1P24" -# PSU PMBus sensors +# Power supplies bus "i2c-3" "i2c-1-mux (chan_id 1)" chip "pmbus-i2c-3-58" label in1 "PSU-1 220V Rail(in)" diff --git a/device/mellanox/x86_64-nvidia_sn5600-r0/sensors.conf b/device/mellanox/x86_64-nvidia_sn5600-r0/sensors.conf index 2a78b7cd65f2..e64aabae645f 100644 --- a/device/mellanox/x86_64-nvidia_sn5600-r0/sensors.conf +++ b/device/mellanox/x86_64-nvidia_sn5600-r0/sensors.conf @@ -288,6 +288,7 @@ chip "dps460-i2c-*-5a" label power2 "PSU-2(R) 12V Rail Pwr (out)" label curr1 "PSU-2(R) 220V Rail Curr (in)" label curr2 "PSU-2(R) 12V Rail Curr (out)" + set power2_cap 0 # Power converters chip "pmbus-i2c-*-10"