From de97ce6eebbfdc25a2eec50b6014a3eb18d435c8 Mon Sep 17 00:00:00 2001 From: TheGeneralist <180094941+thegeneralist01@users.noreply.github.com> Date: Fri, 9 Oct 2026 14:52:41 +0200 Subject: [PATCH] nixos: apply SATA link power policy consistently --- hosts/thegeneralist/hardware-configuration.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hosts/thegeneralist/hardware-configuration.nix b/hosts/thegeneralist/hardware-configuration.nix index f03d750..c3f5505 100644 --- a/hosts/thegeneralist/hardware-configuration.nix +++ b/hosts/thegeneralist/hardware-configuration.nix @@ -41,6 +41,12 @@ fi done + for host in /sys/class/scsi_host/host*; do + if [ -w "$host/link_power_management_policy" ]; then + echo med_power_with_dipm > "$host/link_power_management_policy" + fi + done + # This unmounted archival HDD wakes transparently when accessed. disk=/dev/disk/by-id/ata-ST1000DM010-2EP102_ZN1043CH if [ -b "$disk" ]; then