Skip to content

Commit

Permalink
hw-mgmt: patches: 6.1: Add support for SN5640 sku HI172
Browse files Browse the repository at this point in the history
1. Add kernel support for SN5640 sku:HI172
2. Fix ASIC count for SN5640

Signed-off-by: Oleksandr Shamray <[email protected]>
  • Loading branch information
sholeksandr committed Oct 28, 2024
1 parent 4a1e4e9 commit 0328725
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 28 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 3a0bc91c0436c9f06ff8d3cb8ed28d9ed999374c Mon Sep 17 00:00:00 2001
From 60e5f8cfdf6bd3a18ffef73764e59ccd53bba9ff Mon Sep 17 00:00:00 2001
From: Oleksandr Shamray <[email protected]>
Date: Fri, 11 Oct 2024 11:09:32 +0300
Subject: [PATCH 18/20] platform: mellanox: mlx-platform: Add support for new
Subject: [PATCH 1/3] platform: mellanox: mlx-platform: Add support for new
Nvidia system

Add support for SN5640 Nvidia switch.
Expand All @@ -19,11 +19,11 @@ SN5640 Features:
Signed-off-by: Oleksandr Shamray <[email protected]>
Reviewed-by: Vadim Pasternak <[email protected]>
---
drivers/platform/mellanox/mlx-platform.c | 89 ++++++++++++++++++++++++
1 file changed, 89 insertions(+)
drivers/platform/mellanox/mlx-platform.c | 96 ++++++++++++++++++++++++
1 file changed, 96 insertions(+)

diff --git a/drivers/platform/mellanox/mlx-platform.c b/drivers/platform/mellanox/mlx-platform.c
index f94e2f2f6776..0ac528c4db6b 100644
index f94e2f2f6776..5796e4695a2a 100644
--- a/drivers/platform/mellanox/mlx-platform.c
+++ b/drivers/platform/mellanox/mlx-platform.c
@@ -2131,6 +2131,7 @@ static struct mlxreg_core_data mlxplat_mlxcpld_modular_pwr_items_data[] = {
Expand Down Expand Up @@ -136,7 +136,7 @@ index f94e2f2f6776..0ac528c4db6b 100644
static const struct dmi_system_id mlxplat_dmi_table[] __initconst = {
{
.callback = mlxplat_dmi_default_wc_matched,
@@ -8386,6 +8468,13 @@ static const struct dmi_system_id mlxplat_dmi_table[] __initconst = {
@@ -8386,6 +8468,20 @@ static const struct dmi_system_id mlxplat_dmi_table[] __initconst = {
DMI_MATCH(DMI_BOARD_NAME, "VMOD0019"),
},
},
Expand All @@ -146,6 +146,13 @@ index f94e2f2f6776..0ac528c4db6b 100644
+ DMI_MATCH(DMI_BOARD_NAME, "VMOD0022"),
+ DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "HI171"),
+ },
+ },
+ {
+ .callback = mlxplat_dmi_ng400_hi171_matched,
+ .matches = {
+ DMI_MATCH(DMI_BOARD_NAME, "VMOD0022"),
+ DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "HI172"),
+ },
+ },
{
.callback = mlxplat_dmi_msn274x_matched,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 1d4c63235da4593308c6a6ee989f490edf2ee995 Mon Sep 17 00:00:00 2001
From 862d26a9e9abfc37daf2bbdecf8068e2386e3d0f Mon Sep 17 00:00:00 2001
From: Vadim Pasternak <[email protected]>
Date: Sun, 14 Jan 2024 14:21:57 +0000
Subject: [PATCH 19/20] platform: mellanox: Introduce support of Nvidia L1 tray
Subject: [PATCH 2/3] platform: mellanox: Introduce support of Nvidia L1 tray
DGX switch

Add support for new L1 tray DGX switch node providing L1
Expand All @@ -24,7 +24,7 @@ Signed-off-by: Vadim Pasternak <[email protected]>
1 file changed, 206 insertions(+)

diff --git a/drivers/platform/mellanox/mlx-platform.c b/drivers/platform/mellanox/mlx-platform.c
index 0ac528c4db6b..3fa564ebc034 100644
index 5796e4695a2a..144ee24c11fd 100644
--- a/drivers/platform/mellanox/mlx-platform.c
+++ b/drivers/platform/mellanox/mlx-platform.c
@@ -3059,6 +3059,25 @@ static struct mlxreg_core_data mlxplat_mlxcpld_erot_error_items_data[] = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
From 95d60daf2443af52cb42efbdba1a8a807b7d953c Mon Sep 17 00:00:00 2001
From d6a6b670349391278befeb6ae13fdcc78244a9fa Mon Sep 17 00:00:00 2001
From: Oleksandr Shamray <[email protected]>
Date: Fri, 11 Oct 2024 11:16:01 +0300
Subject: [PATCH 20/20] platform: mellanox: Downstream: Introduce support of
Subject: [PATCH 3/3] platform: mellanox: Downstream: Introduce support of
Nvidia next genration L1 tray switch

Add support for new L1 tray switch node providing L1 connectivity for
Expand All @@ -20,7 +20,7 @@ Signed-off-by: Vadim Pasternak <[email protected]>
1 file changed, 1071 insertions(+), 104 deletions(-)

diff --git a/drivers/platform/mellanox/mlx-platform.c b/drivers/platform/mellanox/mlx-platform.c
index 3fa564ebc034..39fea95fb4dd 100644
index 144ee24c11fd..2192f047ec70 100644
--- a/drivers/platform/mellanox/mlx-platform.c
+++ b/drivers/platform/mellanox/mlx-platform.c
@@ -53,6 +53,7 @@
Expand Down Expand Up @@ -1430,7 +1430,7 @@ index 3fa564ebc034..39fea95fb4dd 100644
{
.callback = mlxplat_dmi_ng400_hi171_matched,
.matches = {
@@ -8769,8 +9736,8 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
@@ -8776,8 +9743,8 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
int i, shift = 0;

/* Scan adapters from expected id to verify it is free. */
Expand All @@ -1441,7 +1441,7 @@ index 3fa564ebc034..39fea95fb4dd 100644
mlxplat_max_adap_num; i++) {
search_adap = i2c_get_adapter(i);
if (search_adap) {
@@ -8779,7 +9746,7 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
@@ -8786,7 +9753,7 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
}

/* Return if expected parent adapter is free. */
Expand All @@ -1450,7 +1450,7 @@ index 3fa564ebc034..39fea95fb4dd 100644
return 0;
break;
}
@@ -8801,7 +9768,7 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
@@ -8808,7 +9775,7 @@ static int mlxplat_mlxcpld_verify_bus_topology(int *nr)
}

/* Shift bus only if mux provided by 'mlxplat_mux_data'. */
Expand Down
15 changes: 2 additions & 13 deletions usr/usr/bin/hw_management_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -306,14 +306,7 @@
],
"HI171|HI172": [
{"fin": "/sys/module/sx_core/asic0/temperature/input",
"fn": "asic_temp_populate",
"arg" : ["asic1"],
"poll": 3, "ts": 0},
{"fin": "/sys/module/sx_core/asic1/temperature/input",
"fn": "asic_temp_populate",
"arg" : ["asic2"],
"poll": 3, "ts": 0},

"fn": "asic_temp_populate", "arg" : ["asic1"], "poll": 3, "ts": 0},
{"fin": "/sys/module/sx_core/asic0/module0/temperature/input",
"fn": "module_temp_populate", "arg" : ["module1"], "poll": 20, "ts": 0},
{"fin": "/sys/module/sx_core/asic0/module1/temperature/input",
Expand Down Expand Up @@ -443,9 +436,7 @@
{"fin": "/sys/module/sx_core/asic0/module63/temperature/input",
"fn": "module_temp_populate", "arg" : ["module64"], "poll": 20, "ts": 0},
{"fin": None,
"fn": "asic_state_poll", "arg" : ["/sys/module/sx_core/asic0/", 0], "poll": 10, "ts": 0},
{"fin": None,
"fn": "asic_state_poll", "arg" : ["/sys/module/sx_core/asic1/", 0], "poll": 10, "ts": 0}
"fn": "asic_state_poll", "arg" : ["/sys/module/sx_core/asic0/", 0], "poll": 10, "ts": 0}
],
"test": [
{"fin": "/tmp/power_button_clr",
Expand Down Expand Up @@ -626,7 +617,6 @@ def asic_state_poll(arg_list, arg):
with open(asics_init_done_fname, 'w+', encoding="utf-8") as f:
f.write(str(asics_init_done)+"\n")


# ----------------------------------------------------------------------
def sync_fan(fan_id, val):
if int(val) == 0:
Expand Down Expand Up @@ -700,7 +690,6 @@ def module_temp_populate(arg_list, arg):
temp_emergency = ""
temp_fault = ""
temp_trip_crit = ""


with open(f_name, 'w', encoding="utf-8") as f:
f.write(str(val))
Expand Down

0 comments on commit 0328725

Please sign in to comment.