2022-12-19 09:09:08 +00:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}: {
|
2022-04-02 08:14:30 +01:00
|
|
|
boot.extraModprobeConfig = "options thinkpad_acpi fan_control=1";
|
|
|
|
services.thinkfan = {
|
|
|
|
enable = true;
|
|
|
|
levels = [
|
2022-12-19 09:09:08 +00:00
|
|
|
[0 0 55]
|
|
|
|
[1 48 60]
|
|
|
|
[2 50 61]
|
|
|
|
[3 52 63]
|
|
|
|
[6 56 70]
|
|
|
|
[7 65 85]
|
|
|
|
["level full-speed" 80 32767]
|
2022-04-02 08:14:30 +01:00
|
|
|
];
|
|
|
|
sensors = [
|
|
|
|
{
|
|
|
|
type = "hwmon";
|
|
|
|
query = "/sys/class/hwmon";
|
|
|
|
name = "coretemp";
|
2022-12-19 09:09:08 +00:00
|
|
|
indices = [1 2 3 4 5];
|
2022-04-02 08:14:30 +01:00
|
|
|
}
|
2022-04-02 10:52:00 +01:00
|
|
|
{
|
|
|
|
type = "hwmon";
|
|
|
|
query = "/sys/class/hwmon";
|
|
|
|
name = "nvme";
|
2022-12-19 09:09:08 +00:00
|
|
|
indices = [1];
|
2022-04-02 10:52:00 +01:00
|
|
|
}
|
|
|
|
{
|
|
|
|
type = "hwmon";
|
|
|
|
query = "/sys/class/hwmon";
|
|
|
|
name = "acpitz";
|
2022-12-19 09:09:08 +00:00
|
|
|
indices = [1];
|
2022-04-02 10:52:00 +01:00
|
|
|
}
|
|
|
|
{
|
|
|
|
type = "hwmon";
|
|
|
|
query = "/sys/class/hwmon";
|
|
|
|
name = "pch_skylake";
|
2022-12-19 09:09:08 +00:00
|
|
|
indices = [1];
|
2022-04-02 10:52:00 +01:00
|
|
|
}
|
2022-04-02 08:14:30 +01:00
|
|
|
{
|
|
|
|
type = "tpacpi";
|
|
|
|
query = "/proc/acpi/ibm/thermal";
|
2022-12-19 09:09:08 +00:00
|
|
|
indices = [0 1];
|
2022-04-02 08:14:30 +01:00
|
|
|
}
|
|
|
|
];
|
|
|
|
};
|
|
|
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
|
|
|
}
|