diff options
author | Elian Doran <contact@eliandoran.me> | 2023-01-12 21:18:37 +0200 |
---|---|---|
committer | pennae <82953136+pennae@users.noreply.github.com> | 2023-01-14 19:33:48 +0100 |
commit | ba0a640afd06deb62f88c93e9b4118036c1090fa (patch) | |
tree | 80fea95237f35b0a8ff107e4ac61a258fb750a15 /nixos | |
parent | ae8876eace418f5e558f64170ce9242a2714305a (diff) |
fancontrol: restart service after suspend
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/hardware/fancontrol.nix | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/nixos/modules/services/hardware/fancontrol.nix b/nixos/modules/services/hardware/fancontrol.nix index e7eb8ebf92be5..993c37b2364f8 100644 --- a/nixos/modules/services/hardware/fancontrol.nix +++ b/nixos/modules/services/hardware/fancontrol.nix @@ -42,6 +42,13 @@ in ExecStart = "${pkgs.lm_sensors}/sbin/fancontrol ${configFile}"; }; }; + + # On some systems, the fancontrol service does not resume properly after sleep because the pwm status of the fans + # is not reset properly. Restarting the service fixes this, in accordance with https://github.com/lm-sensors/lm-sensors/issues/172. + powerManagement.resumeCommands = '' + systemctl restart fancontrol.service + ''; + }; meta.maintainers = [ maintainers.evils ]; |