From cafa961887b6a2fc1f26a9dead4b8140c21c0ab6 Mon Sep 17 00:00:00 2001 From: Yuanzhe <150663541+yuazhe@users.noreply.github.com> Date: Mon, 4 Nov 2024 14:39:35 +0800 Subject: [PATCH] [Mellanox] updating sensors.conf and psu_sensors.json accordingly (#19927) - Why I did it Support new psu model and align to hw definition - How I did it Add psu model MTEF-AC-I data to psu_sensors.json Add place holder for model MTEF-AC-G-DELTA Fix 4700/4700a1 inverted psu designation - How to verify it check the sensors command output on system with the psu model MTEF-AC-I Signed-off-by: Yuanzhe, Liu --- .../x86_64-mlnx_msn2700-r0/psu_sensors.json | 23 +++++++++++++---- .../x86_64-mlnx_msn4700-r0/sensors.conf | 24 +++++++++--------- .../x86_64-mlnx_msn4700-r0/sensors.conf.a1 | 25 ++++++++++--------- 3 files changed, 43 insertions(+), 29 deletions(-) diff --git a/device/mellanox/x86_64-mlnx_msn2700-r0/psu_sensors.json b/device/mellanox/x86_64-mlnx_msn2700-r0/psu_sensors.json index 73f011e29d71..abd2e8a183f1 100644 --- a/device/mellanox/x86_64-mlnx_msn2700-r0/psu_sensors.json +++ b/device/mellanox/x86_64-mlnx_msn2700-r0/psu_sensors.json @@ -219,8 +219,8 @@ "i2c-1-mux (chan_id 3)" ], "chip": { - "dps460-i2c-*-58": ["1", "L"], - "dps460-i2c-*-59": ["2", "R"] + "dps460-i2c-*-58": ["2", "R"], + "dps460-i2c-*-59": ["1", "L"] } }, "a1": { @@ -229,8 +229,8 @@ "i2c-1-mux (chan_id 3)" ], "chip": { - "dps460-i2c-*-58": ["1", "L"], - "dps460-i2c-*-59": ["2", "R"] + "dps460-i2c-*-58": ["2", "R"], + "dps460-i2c-*-59": ["1", "L"] } } }, @@ -376,8 +376,21 @@ "curr2 PSU 12V Rail Curr (out)" ] }, - "MTEF-AC-I": { + "MTEF-AC-G-DELTA":{ + }, + "MTEF-AC-I": { + "label": [ + "in1 PSU 220V Rail (in)", + "in2 PSU 12V Rail (out)", + "fan1 PSU Fan 1", + "temp1 PSU Temp 1", + "temp2 PSU Temp 2", + "power1 PSU 220V Rail Pwr (in)", + "power2 PSU 12V Rail Pwr (out)", + "curr1 PSU 220V Rail Curr (in)", + "curr2 PSU 12V Rail Curr (out)" + ] }, "MTEF-AC-M": { "label": [ diff --git a/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf b/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf index 280118e43ef1..6b6205cc5493 100644 --- a/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf +++ b/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf @@ -188,18 +188,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" - 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)" @@ -211,6 +199,18 @@ 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" + 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_msn4700-r0/sensors.conf.a1 b/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf.a1 index e85dca5aecba..af5b9c33cd4f 100644 --- a/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf.a1 +++ b/device/mellanox/x86_64-mlnx_msn4700-r0/sensors.conf.a1 @@ -133,18 +133,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" - 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)" @@ -156,6 +144,19 @@ 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" + 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-*"