summary refs log tree commit diff
path: root/gnu
diff options
context:
space:
mode:
authorJelle Licht <jlicht@fsfe.org>2022-03-12 21:34:09 +0100
committerJelle Licht <jlicht@fsfe.org>2022-03-20 16:40:22 +0100
commit10d865aa921f559562fb543d7796c7a08e17f016 (patch)
tree9b608a6192adbf807c8e6a467e5a9ae36ba29683 /gnu
parent01d433250fe03326b4ea305d527c0294ed2eb037 (diff)
downloadguix-10d865aa921f559562fb543d7796c7a08e17f016.tar.gz
services: thermald: Add 'adaptive?' field.
* gnu/services/pm.scm (<thermald-configuration>): Add 'adaptive?' field.
(thermald-shepherd-service): Use it to pass --adaptive to thermald.
* doc/guix.texi (Power Management Services): Document the 'adaptive?' field of
'thermald-configuration'.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/services/pm.scm5
1 files changed, 5 insertions, 0 deletions
diff --git a/gnu/services/pm.scm b/gnu/services/pm.scm
index 3da3c0b961..e48236dbca 100644
--- a/gnu/services/pm.scm
+++ b/gnu/services/pm.scm
@@ -435,6 +435,8 @@ shutdown on system startup."))
 (define-record-type* <thermald-configuration>
   thermald-configuration make-thermald-configuration
   thermald-configuration?
+  (adaptive?           thermald-adaptive?              ;boolean
+                       (default #f))
   (ignore-cpuid-check? thermald-ignore-cpuid-check?    ;boolean
                        (default #f))
   (thermald            thermald-thermald               ;file-like
@@ -448,6 +450,9 @@ shutdown on system startup."))
     (start #~(make-forkexec-constructor
               '(#$(file-append (thermald-thermald config) "/sbin/thermald")
                 "--no-daemon"
+                #$@(if (thermald-adaptive? config)
+                       '("--adaptive")
+                       '())
                 #$@(if (thermald-ignore-cpuid-check? config)
                        '("--ignore-cpuid-check")
                        '()))))