Add CPU Boost controller systemd services
This commit is contained in:
parent
4c19c89935
commit
f9a6658fea
2 changed files with 23 additions and 0 deletions
12
limit-cpu-power.service
Normal file
12
limit-cpu-power.service
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
[Unit]
|
||||||
|
Description=Limit CPU power on startup
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=oneshot
|
||||||
|
RemainAfterExit=yes
|
||||||
|
ExecStart=sh -c 'echo 90 | sudo tee /sys/devices/system/cpu/intel_pstate/max_perf_pct'
|
||||||
|
ExecStop=sh -c 'echo 100 | sudo tee /sys/devices/system/cpu/intel_pstate/max_perf_pct'
|
||||||
|
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target default.target
|
11
no-turbo.service
Normal file
11
no-turbo.service
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
[Unit]
|
||||||
|
Description=Disable Turbo Boost on startup
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=oneshot
|
||||||
|
RemainAfterExit=yes
|
||||||
|
ExecStart=sh -c 'echo 1 > /sys/devices/system/cpu/intel_pstate/no_turbo'
|
||||||
|
ExecStop=sh -c 'echo 0 > /sys/devices/system/cpu/intel_pstate/no_turbo'
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target default.target
|
Loading…
Reference in a new issue