tried fixing freezes

This commit is contained in:
2025-09-26 09:42:29 +02:00
parent 03fa3736fe
commit 2e72caad36
+39 -46
View File
@@ -1,76 +1,69 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{
config,
lib,
pkgs,
modulesPath,
...
}:
{ config, lib, pkgs, modulesPath, ... }:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
#boot.kernelPackages = pkgs.linuxPackages_xanmod_latest;
#boot.kernelPackages = pkgs.linuxPackages_latest;
boot.kernelPackages = pkgs.linuxPackages_zen;
boot.initrd.availableKernelModules = [
"xhci_pci"
"nvme"
"uas"
"rtsx_pci_sdmmc"
boot.kernelParams = [
"nvme_core.default_ps_max_latency_us=0"
"pcie_aspm=off"
"pcie_port_pm=off"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "uas" "rtsx_pci_sdmmc" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-label/NIXROOT";
fsType = "ext4";
};
boot.initrd.luks.devices = {
"luks_secure" = {
device = "/dev/disk/by-uuid/c21c8089-29a7-4266-a8a6-6e80ccca167c";
#preLVM = true;
#allowDiscards = true;
crypttabExtraOpts = [
"tpm2-device=auto"
"tpm2-measure-pcr=yes"
];
};
fileSystems."/boot" = {
device = "/dev/disk/by-label/NIXBOOT";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
boot.initrd.luks.devices.luks_secure = {
device = "/dev/disk/by-uuid/c21c8089-29a7-4266-a8a6-6e80ccca167c";
crypttabExtraOpts = [
"tpm2-device=auto"
"tpm2-measure-pcr=yes"
];
};
services.logind.lidSwitch = "suspend-then-hibernate";
powerManagement.enable = true;
swapDevices = [
{
device = "/swapfile";
size = 98 * 1024; # 32GB in MB
}
];
fileSystems."/boot" = {
device = "/dev/disk/by-label/NIXBOOT";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
boot.kernel.sysctl = {
"vm.swappiness" = 10;
};
services.logind.lidSwitch = "suspend-then-hibernate";
powerManagement.enable = true;
hardware.graphics = {
enable = true;
extraPackages = with pkgs; [
vpl-gpu-rt
intel-media-sdk
];
enable = true;
extraPackages = with pkgs; [ vpl-gpu-rt intel-media-sdk ];
};
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}