Compare commits

..

No commits in common. "a1653874cbdbb87cec1044b53cbc77dc15758e79" and "d4c0043a057d4fd05aea94c23470e419c12fef35" have entirely different histories.

6 changed files with 19 additions and 67 deletions

View file

@ -1,5 +1,7 @@
{ ... }: {
services = {
thermald.enable = false;
throttled.enable = true;
power-profiles-daemon.enable = false; # replacement for tlp and auto-cpufreq due to bugs
tlp = {
enable = false; # buggy and inconsistent with frequency scaling
@ -53,20 +55,29 @@
charger = {
governor = "performance";
energy_performance_preference = "performance";
turbo = "always";
turbo = "auto";
platform_profile = "performance";
scaling_min_freq = 800000;
scaling_max_freq = 3600000;
};
battery = {
governor = "powersave";
energy_performance_preference = "balance-power";
energy_performance_preference = "power";
platform_profile = "low-power";
turbo = "never";
scaling_min_freq = 400000;
scaling_max_freq = 1700000;
scaling_max_freq = 1000000;
};
};
};
thinkfan = {
enable = true;
levels = [
[ "level auto" 0 55 ]
[ 3 55 65 ]
[ 7 65 75 ]
[ "level full-speed" 75 100 ]
];
};
};
}

View file

@ -2,7 +2,7 @@
imports = [
./misc/battery-power.nix
./misc/power-button.nix
./misc/cpu-freq.nix
./misc/cpu-thermal.nix
./misc/tzupdate.nix
./core/hibernation.nix
./core/firmware.nix
@ -14,64 +14,10 @@
kernelPackages = pkgs.linuxPackages;
kernel.sysctl."vm.laptop_mode" = 5;
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 = {
enable = true;
powerOnBoot = false;
};
services = {
throttled = {
enable = true;
extraConfig = ''
[GENERAL]
Enabled: True
Update_Rate_s: 30
[BATTERY]
Update_Rate_s: 30
PL1_Tdp_W: 12
PL1_Duration_s: 28
PL2_Tdp_W: 20
PL2_Duration_s: 0.002
Trip_Temp_C: 85
[AC]
Update_Rate_s: 5
PL1_Tdp_W: 25
PL1_Duration_s: 28
PL2_Tdp_W: 35
PL2_Duration_s: 0.002
Trip_Temp_C: 90
[UNDERVOLT]
CORE: -100
GPU: -80
CACHE: -100
UNCORE: -80
ANALOGIO: 0
'';
};
thinkfan = {
enable = true;
levels = [
[ "level auto" 0 55 ]
[ 3 55 65 ]
[ 7 65 75 ]
[ "level full-speed" 75 100 ]
];
};
hardware.bolt.enable = true;
};
services.hardware.bolt.enable = true;
}

View file

@ -25,7 +25,6 @@
nwg-displays
lxqt.pcmanfm-qt
hyprshot wl-clipboard cliphist
hyprshutdown
];
};
}

View file

@ -141,7 +141,6 @@
"no_anim on, match:namespace selection" # hyprshot overlay
"animation fade, match:namespace swww-daemon"
"animation fade, match:namespace logout_dialog"
"animation fade, match:namespace hyprshutdown"
"above_lock 1, match:namespace waybar"
"above_lock 2, match:namespace notifications"
"above_lock 2, match:namespace selection"

View file

@ -4,13 +4,13 @@
layout = [
{
label = "shutdown";
action = "hyprshutdown -t 'Shutting down...' --post-cmd 'systemctl poweroff'";
action = "systemctl poweroff";
text = "(S)hutdown";
keybind = "s";
}
{
label = "reboot";
action = "hyprshutdown -t 'Rebooting...' --post-cmd 'systemctl reboot'";
action = "systemctl reboot";
text = "(R)eboot";
keybind = "r";
}
@ -28,7 +28,7 @@
}
{
label = "logout";
action = "hyprshutdown -t 'Logging Out...' --post-cmd 'uwsm stop'";
action = "uwsm stop";
text = "L(o)gout";
keybind = "o";
}

View file

@ -46,10 +46,7 @@
sysstat
netcat
p7zip
throttled
tlp
stress
stress-ng
wakeonlan
coreutils-full
traceroute