undervolt tweaks
This commit is contained in:
parent
d4c0043a05
commit
d9982d992f
2 changed files with 49 additions and 14 deletions
|
|
@ -1,7 +1,5 @@
|
||||||
{ ... }: {
|
{ ... }: {
|
||||||
services = {
|
services = {
|
||||||
thermald.enable = false;
|
|
||||||
throttled.enable = true;
|
|
||||||
power-profiles-daemon.enable = false; # replacement for tlp and auto-cpufreq due to bugs
|
power-profiles-daemon.enable = false; # replacement for tlp and auto-cpufreq due to bugs
|
||||||
tlp = {
|
tlp = {
|
||||||
enable = false; # buggy and inconsistent with frequency scaling
|
enable = false; # buggy and inconsistent with frequency scaling
|
||||||
|
|
@ -66,18 +64,9 @@
|
||||||
platform_profile = "low-power";
|
platform_profile = "low-power";
|
||||||
turbo = "never";
|
turbo = "never";
|
||||||
scaling_min_freq = 400000;
|
scaling_min_freq = 400000;
|
||||||
scaling_max_freq = 1000000;
|
scaling_max_freq = 1700000;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
thinkfan = {
|
|
||||||
enable = true;
|
|
||||||
levels = [
|
|
||||||
[ "level auto" 0 55 ]
|
|
||||||
[ 3 55 65 ]
|
|
||||||
[ 7 65 75 ]
|
|
||||||
[ "level full-speed" 75 100 ]
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
./misc/battery-power.nix
|
./misc/battery-power.nix
|
||||||
./misc/power-button.nix
|
./misc/power-button.nix
|
||||||
./misc/cpu-thermal.nix
|
./misc/cpu-freq.nix
|
||||||
./misc/tzupdate.nix
|
./misc/tzupdate.nix
|
||||||
./core/hibernation.nix
|
./core/hibernation.nix
|
||||||
./core/firmware.nix
|
./core/firmware.nix
|
||||||
|
|
@ -14,10 +14,56 @@
|
||||||
kernelPackages = pkgs.linuxPackages;
|
kernelPackages = pkgs.linuxPackages;
|
||||||
kernel.sysctl."vm.laptop_mode" = 5;
|
kernel.sysctl."vm.laptop_mode" = 5;
|
||||||
initrd.availableKernelModules = [ "thinkpad_acpi" ];
|
initrd.availableKernelModules = [ "thinkpad_acpi" ];
|
||||||
|
kernelParams = [
|
||||||
|
"i915.enable_psr=1"
|
||||||
|
"pcie_aspm=force"
|
||||||
|
"nmi_watchdog=0"
|
||||||
|
# ^^ potential instability, but improves battery life
|
||||||
|
|
||||||
|
"loglevel=3"
|
||||||
|
"i915.enable_guc=3"
|
||||||
|
"i915.enable_fbc=1"
|
||||||
|
"msr.allow-writes=on"
|
||||||
|
"nvme_core.default_ps_max_latency_us=0"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
hardware.bluetooth = {
|
hardware.bluetooth = {
|
||||||
enable = true;
|
enable = true;
|
||||||
powerOnBoot = false;
|
powerOnBoot = false;
|
||||||
};
|
};
|
||||||
services.hardware.bolt.enable = true;
|
services = {
|
||||||
|
throttled = {
|
||||||
|
enable = true;
|
||||||
|
extraConfig = ''
|
||||||
|
[UNDERVOLT]
|
||||||
|
CORE: -120
|
||||||
|
GPU: -80
|
||||||
|
CACHE: -120
|
||||||
|
UNCORE: -80
|
||||||
|
ANALOGIO: 0
|
||||||
|
|
||||||
|
[BATTERY]
|
||||||
|
PL1_Tdp_W: 12
|
||||||
|
PL2_Tdp_W: 20
|
||||||
|
PL1_Duration_s: 28
|
||||||
|
PL2_Duration_s: 0.002
|
||||||
|
Update_Rate_s: 30
|
||||||
|
Trip_Temp_C: 85
|
||||||
|
|
||||||
|
[AC]
|
||||||
|
PL1_Tdp_W: 25
|
||||||
|
PL2_Tdp_W: 35
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
thinkfan = {
|
||||||
|
enable = true;
|
||||||
|
levels = [
|
||||||
|
[ "level auto" 0 55 ]
|
||||||
|
[ 3 55 65 ]
|
||||||
|
[ 7 65 75 ]
|
||||||
|
[ "level full-speed" 75 100 ]
|
||||||
|
];
|
||||||
|
};
|
||||||
|
hardware.bolt.enable = true;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue