From 9c649d16e1af2e67a0c437b396fd8e13570d2902 Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Tue, 31 Jul 2018 18:57:57 +0000 Subject: [PATCH] Fix: CPU sensors count on MQM8700 system Signed-off-by: Oleksandr Shamray --- .../onlp/builds/src/module/src/thermali.c | 13 +++---------- .../src/python/x86_64_mlnx_mqm8700_r0/__init__.py | 2 +- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c index 7011410d..fedbf1b3 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c @@ -36,8 +36,7 @@ enum onlp_thermal_id THERMAL_RESERVED = 0, THERMAL_CPU_CORE_0, THERMAL_CPU_CORE_1, - THERMAL_CPU_CORE_2, - THERMAL_CPU_CORE_3, + THERMAL_CPU_PACK, THERMAL_ASIC, THERMAL_BOARD_AMB, THERMAL_PORT, @@ -50,8 +49,7 @@ static char* thermal_fnames[] = /* must map with onlp_thermal_id */ "reserved", "cpu_core0", "cpu_core1", - "cpu_core2", - "cpu_core3", + "cpu_pack", "asic", "board_amb", "port_amb", @@ -71,12 +69,7 @@ static onlp_thermal_info_t tinfo[] = { ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS }, - { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_0), "CPU Core 2", 0}, - ONLP_THERMAL_STATUS_PRESENT, - ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS - }, - - { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_1), "CPU Core 3", 0}, + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_PACK), "CPU pack", 0}, ONLP_THERMAL_STATUS_PRESENT, ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS }, diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py index c704cb97..99fc6c29 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py @@ -5,7 +5,7 @@ class OnlPlatform_x86_64_mlnx_mqm8700_r0(OnlPlatformMellanox, OnlPlatformPortConfig_32x100): PLATFORM='x86-64-mlnx-mqm8700-r0' MODEL="MQM8700" - SYS_OBJECT_ID=".700.1" + SYS_OBJECT_ID=".8700.1" def baseconfig(self): # load modules