Browse Source

hibernate, ++

Johan Rong 1 tháng trước cách đây
mục cha
commit
18f0c97fac

+ 5 - 1
hosts/nixstation/nixos/default.nix

@@ -15,7 +15,7 @@ in
     ../../../nixos/profiles/gaming
     ../../../nixos/profiles/school
 
-    ../../../nixos/modules/hardware/gpu/nvidia.nix
+    ../../../nixos/modules/hardware/graphics/nvidia.nix
     ../../../nixos/modules/hardware/networking/bcm4360.nix
     ../../../nixos/modules/hardware/sound
     ../../../nixos/modules/hardware/bluetooth
@@ -24,5 +24,9 @@ in
     ../../../nixos/modules/desktop/hyprland/greeter-default.nix
   ];
   
+  boot.kernelParams = [
+    "resume=UUID=ba1f1991-b3cf-4bb3-8558-da54c9afa148"
+  ];
+
   networking.hostName = hosts.nixstation.hostname;
 }

+ 0 - 0
nixos/modules/hardware/gpu/nvidia-open.nix → nixos/modules/hardware/graphics/nvidia-open.nix


+ 5 - 0
nixos/modules/hardware/gpu/nvidia.nix → nixos/modules/hardware/graphics/nvidia.nix

@@ -18,6 +18,11 @@
       enable = true;
     };
 
+    powerManagement = {
+      enable = true;
+      finegrained = false;
+    };
+
     nvidiaSettings = true;
     package = config.boot.kernelPackages.nvidiaPackages.stable;
   };