Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support thermalcltd build, add default policy files as well as build-time unit test support for platform API #5

Closed
wants to merge 71 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
cf98224
Add make support for thermal control feature
Junchao-Mellanox Nov 28, 2019
f428c1c
[sonic_platform]fix issues found in thermal ctrl:
Nov 28, 2019
2b4089d
[sonic_platform]fix issues found in thermal ctrl:
Nov 28, 2019
25a3aef
[sonic_platform]add get_name for fan and psu
Nov 28, 2019
325840c
[sonic_platform]fix divide-by-zero error due to max speed for psu fan…
Dec 2, 2019
952393f
[thermal.py]handle get_high_critical_threshold
Dec 4, 2019
1d83717
Move task_base form sonic-platform-daemon to sonic-daemon-base so tha…
Junchao-Mellanox Dec 6, 2019
77a1d4b
Merge branch 'thermal-control' of https://github.com/Junchao-Mellanox…
Junchao-Mellanox Dec 12, 2019
ff562c9
Merge from stephen to fix thermal related issues
Junchao-Mellanox Dec 13, 2019
6f1e2c3
[fan.py]fix error in get_target_speed for PSU fan
Dec 13, 2019
fa8273b
Add thermal policy JSON file for mellanox devices
Junchao-Mellanox Dec 16, 2019
aeee985
Fix issue found by manual test
Junchao-Mellanox Dec 16, 2019
d27f67b
add default thermal control implementation to mellanox platform api a…
Junchao-Mellanox Dec 18, 2019
5773bb2
add unit test support for sonic thermalctld
Junchao-Mellanox Dec 18, 2019
9772e30
rename some functions to make it more readable according to Kebo comm…
Junchao-Mellanox Dec 19, 2019
d4de5d8
add check for speed value in thermal actions to avoid load invalid value
Junchao-Mellanox Dec 19, 2019
183a42b
add unit test to cover thermal conditions and actions
Junchao-Mellanox Dec 20, 2019
27803f3
Change according to stepan comment
Junchao-Mellanox Dec 23, 2019
af996c7
1. Add base class for FanConditions and PsuConditions; 2. Add default…
Junchao-Mellanox Dec 24, 2019
704228c
remove thermalctld from critical_processes
Junchao-Mellanox Dec 24, 2019
87f7010
SONiC Management Framework Release 1.0 (#3488)
PrabhuSreenivasan Dec 24, 2019
3d9bf8a
add default thermal manager getter in chassis.py
Junchao-Mellanox Dec 24, 2019
e479f4e
add implementation for start and stop thermal algorithm
Junchao-Mellanox Dec 25, 2019
c865626
add unit test for thermal algorithm related JSON config
Junchao-Mellanox Dec 26, 2019
dcc232e
adjust thermal_policy.json to make it compatible with current platfor…
Junchao-Mellanox Dec 26, 2019
baea7e2
[slave.mk] make curl follow HTTP redirects (#3947)
stepanblyschak Dec 27, 2019
86ab2ae
[swsssdk-py] submodule update for sonic-py-swsssdk (#3929)
dzhangalibaba Dec 27, 2019
18cb5c6
[swss] submodule update (#3925)
stepanblyschak Dec 27, 2019
bd72844
[kvm]: increase the kvm installer size to 2G for dbg image
lguohan Dec 28, 2019
78db080
corefile uploader: Updates per review comments offline (#3915)
renukamanavalan Dec 30, 2019
08cde06
[Juniper][QFX5210] Adding qos.json (#3946)
ciju-juniper Dec 31, 2019
24a0c46
[monit] Build from source and patch to use MemAvailable value if avai…
jleveque Dec 31, 2019
ea11287
[Mellanox] Update FW/SDK: 13/29.2000.2696 and 4.3.2904 (#3948)
noaOrMlnx Dec 31, 2019
476be91
[docker-base-stretch]: Do not check expire for stretch-backports repo…
lguohan Jan 1, 2020
0dae59a
[MultiDB]except src and dockers : replace redis-cli with sonic-db-cli…
dzhangalibaba Jan 2, 2020
1221246
Update bgpcfgd with vrf support (#3952)
pavel-shirshov Jan 4, 2020
df04809
[libnl]: Debian Packaging libnl version 3.5.0 (#3967)
tahmed-dev Jan 7, 2020
bef6699
Change PSU FAN naming rule
Junchao-Mellanox Jan 7, 2020
04b9113
[Mellanox]Update the hw-mgmt patch for simx on V.7.0000.2308 (#3957)
stephenxs Jan 7, 2020
3548587
[apt] Instruct apt-get to NOT check the "Valid Until" date in Release…
jleveque Jan 7, 2020
2658ab8
[dhcp-relay]: Add DHCP Relay Monitor (#3886)
tahmed-dev Jan 8, 2020
68499e6
[sonic-mgmt]: Install python-subnettree to sonic-mgmt container. (#3978)
iris00522 Jan 8, 2020
c475519
Fix bug: chroot command line (#3972)
qiluo-msft Jan 8, 2020
483a594
Revert "[MultiDB]except src and dockers : replace redis-cli with soni…
lguohan Jan 10, 2020
856b4b6
[reboot cause]: Delay process-reboot-cause service until network conn…
sujinmkang Jan 10, 2020
bac6615
[device/celestica]: Fix xcvrd error (#3979)
Jan 10, 2020
e45ff4e
[build] make debian package install noninteractive (#3980)
stepanblyschak Jan 10, 2020
f3b5b13
[barefoot]: Update SDK package (#3950)
akokhan Jan 10, 2020
aa67921
[Monit] Change the monitoring period from 120 seconds to 60 seconds. …
yozhao101 Jan 10, 2020
6dcc08e
[psud]: Fix for psud crash because of database connection reset (#3647)
Kalimuthu-Velappan Jan 10, 2020
3b1ee5d
Changes to build restapi docker (#3993)
sumukhatv Jan 10, 2020
b7e48b4
[Services] Allow monit system tool to monitor the critical processes …
yozhao101 Jan 11, 2020
952dfb1
[docker-sonic-mgmt]: fix installation permission issue
lguohan Jan 12, 2020
918fdc6
[sflow]: Upgrade hsflowd to v2.0.26-3 (#4020)
padmanarayana Jan 14, 2020
ebb07d9
[docker-restapi]: Avoid building RestAPI docker by default (#4018)
sumukhatv Jan 15, 2020
237835f
Change MFT version to 14.13.3 (#4022)
noaOrMlnx Jan 15, 2020
9a089c2
[mellanox] Update FW to 13/29.2000.2714. (#3998)
nazariig Jan 15, 2020
6bd17d4
[initramfs] Updated required tools for initramfs (#3734)
antony-rheneus Jan 15, 2020
5229163
[Celestica/Seastone2] Add support Seastone2 device and platform (#3761)
pphuchar Jan 16, 2020
4c526d9
[device/celestica]: Implement Silverstone platform API [THERMAL/COMPO…
Jan 16, 2020
4c46178
[device/celestica]: Implement SFP API (#3869)
Jan 16, 2020
2eda2d8
[sonic-py-swsssdk] update submodule for sonic-py-swsssdk (#4031)
dzhangalibaba Jan 17, 2020
4e3bf84
[mgmt-framework] submodule update (#4030)
tahmed-dev Jan 17, 2020
d150721
modified down rules to pre-down rules to ensure that default route is…
kannankvs Jan 17, 2020
b45d2b4
[arista]: Add support for bald eagle phy (#3922)
byu343 Jan 17, 2020
64500e1
[Arista] Update drivers and boot script (#3959)
Staphylo Jan 17, 2020
05d61b5
[bgpcfgd]: Fix bgpcfgd. Don't notify before all deps are ready. (#4027)
pavel-shirshov Jan 17, 2020
f636ae9
[barefoot]: updated SDK to 9.1.0 released debian packages (#4032)
Jan 17, 2020
1886bdf
[Mellanox] fix gearbox ambient thermal name (#4005)
stephenxs Jan 17, 2020
aca1a86
[caclmgrd] Fix application of IPv6 service ACL rules (part 2) (#4036)
jleveque Jan 18, 2020
7521051
Merge branch 'master' into thermal-policy
Junchao-Mellanox Jan 19, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[sonic_platform]fix divide-by-zero error due to max speed for psu fan…
… unsupported and treat 0.0 as N/A in high_threshold in xsfp module
Stephen Sun committed Dec 2, 2019
commit 325840c83776cc16e14d99cae280a9a78e344472
8 changes: 6 additions & 2 deletions platform/mellanox/mlnx-platform-api/sonic_platform/fan.py
Original file line number Diff line number Diff line change
@@ -42,8 +42,8 @@ def __init__(self, fan_index, drawer_index = 1, psu_fan = False):
else:
self.fan_speed_get_path = "psu{}_fan1_speed_get".format(self.index)
self.fan_presence_path = "psu{}_fan1_speed_get".format(self.index)
self.fan_max_speed_path = "psu{}_max".format(self.index)
self._name = "fan(PSU{})".format(fan_index)
self.fan_max_speed_path = None
self.fan_status_path = "fan{}_fault".format(self.index)
self.fan_green_led_path = "led_fan{}_green".format(self.drawer_index)
self.fan_red_led_path = "led_fan{}_red".format(self.drawer_index)
@@ -128,7 +128,11 @@ def get_speed(self):
speed_in_rpm = int(fan_curr_speed.read())
except (ValueError, IOError):
speed_in_rpm = 0


if self.fan_max_speed_path is None:
# in case of max speed unsupported, we just return speed in unit of RPM.
return speed_in_rpm

max_speed_in_rpm = self._get_max_speed_in_rpm()
speed = 100*speed_in_rpm/max_speed_in_rpm

4 changes: 4 additions & 0 deletions platform/mellanox/mlnx-platform-api/sonic_platform/thermal.py
Original file line number Diff line number Diff line change
@@ -37,6 +37,8 @@
THERMAL_API_GET_TEMPERATURE = "get_temperature"
THERMAL_API_GET_HIGH_THRESHOLD = "get_high_threshold"

THERMAL_API_INVALID_HIGH_THRESHOLD = 0.0

HW_MGMT_THERMAL_ROOT = "/var/run/hw-management/thermal/"

thermal_api_handler_cpu_core = {
@@ -353,4 +355,6 @@ def get_high_threshold(self):
if value_str is None:
return None
value_float = float(value_str)
if self.category == THERMAL_DEV_CATEGORY_MODULE and value_float == THERMAL_API_INVALID_HIGH_THRESHOLD:
return None
return value_float / 1000.0