Increase power saving measures

This commit is contained in:
2023-01-19 12:52:49 +01:00
parent 9034cd6f3c
commit e9bcb7bfdf
2 changed files with 14 additions and 2 deletions

View File

@@ -12,9 +12,11 @@
};
};
# Suspend when the battery is critical
# Suspend when the battery is critical and autosuspend USB and PCI
services.udev.extraRules = ''
SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{model_name}=="01AV405", ATTR{capacity}=="[0-5]", RUN+="${config.systemd.package}/bin/systemctl suspend -i"
ACTION=="add", SUBSYSTEM=="usb", TEST=="power/control", ATTR{power/control}="auto"
ACTION=="add", SUBSYSTEM=="pci", TEST=="power/control", ATTR{power/control}="auto"
'';
# Undervolt CPU and GPU
@@ -26,4 +28,11 @@
# Prevent overheating of the CPU
services.thermald.enable = true;
# Provide power management support to programs
services.upower.enable = true;
# Turn off keyboard backlight when unused
services.tp-auto-kbbl.enable = true;
}