From 132e4122cdc181c26cf9e3961d4052ebcabf932e Mon Sep 17 00:00:00 2001 From: Dmitry Voronin Date: Wed, 11 Dec 2024 10:39:21 +0300 Subject: [PATCH] Max: Limix tctl to 50 degrees. --- host/x86_64-linux/max/Power.nix | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/host/x86_64-linux/max/Power.nix b/host/x86_64-linux/max/Power.nix index caead875..8ffb9034 100644 --- a/host/x86_64-linux/max/Power.nix +++ b/host/x86_64-linux/max/Power.nix @@ -2,7 +2,7 @@ pkgs, ... }: { - hardware.cpu.amd.ryzen-smu.enable = true; + # hardware.cpu.amd.ryzen-smu.enable = true; environment.systemPackages = with pkgs; [ # SRC: https://github.com/FlyGoat/RyzenAdj @@ -13,4 +13,21 @@ # SRC: https://github.com/nbfc-linux/nbfc-linux nbfc-linux ]; + + systemd.services.radj = { + enable = true; + description = "Ryzen Adj temperature limiter."; + serviceConfig.Type = "simple"; + wantedBy = [ "multi-user.target" ]; + path = with pkgs; [ + coreutils + ryzenadj + ]; + script = '' + while true; do + ryzenadj --tctl-temp=50 + sleep 60 + done + ''; + }; }