2023-12-23 02:33:26 -05:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
modulesPath,
|
2024-02-11 12:31:29 -05:00
|
|
|
pkgs,
|
2023-12-23 02:33:26 -05:00
|
|
|
...
|
|
|
|
}: {
|
|
|
|
nixpkgs.hostPlatform = "x86_64-linux";
|
|
|
|
imports = [(modulesPath + "/installer/scan/not-detected.nix")];
|
|
|
|
|
|
|
|
boot = {
|
2024-02-17 14:52:43 -05:00
|
|
|
kernelPackages = pkgs.linuxPackages_zen;
|
2023-12-23 02:33:26 -05:00
|
|
|
|
2024-02-17 14:52:43 -05:00
|
|
|
kernelParams = ["amd_pstate=active"];
|
2023-12-23 02:33:26 -05:00
|
|
|
kernelModules = ["kvm-amd"];
|
2024-02-17 14:52:43 -05:00
|
|
|
|
|
|
|
# Zenpower for ryzen cpu monitoring
|
|
|
|
extraModulePackages = with config.boot.kernelPackages; [zenpower];
|
|
|
|
blacklistedKernelModules = ["k10temp"];
|
|
|
|
|
2023-12-23 02:33:26 -05:00
|
|
|
initrd.availableKernelModules = [
|
|
|
|
"nvme"
|
|
|
|
"xhci_pci"
|
|
|
|
"ahci"
|
|
|
|
"usb_storage"
|
|
|
|
"usbhid"
|
|
|
|
"sd_mod"
|
|
|
|
];
|
2024-02-11 12:31:29 -05:00
|
|
|
|
|
|
|
loader = {
|
2024-02-17 14:52:43 -05:00
|
|
|
efi.canTouchEfiVariables = true;
|
2024-02-11 12:31:29 -05:00
|
|
|
timeout = 2;
|
|
|
|
|
2024-02-17 14:52:43 -05:00
|
|
|
systemd-boot = {
|
|
|
|
enable = true;
|
|
|
|
consoleMode = "max";
|
|
|
|
configurationLimit = 30;
|
|
|
|
};
|
2024-02-11 12:31:29 -05:00
|
|
|
};
|
2023-12-23 02:33:26 -05:00
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems = {
|
|
|
|
"/" = {
|
|
|
|
device = "/dev/disk/by-label/NIXROOT";
|
|
|
|
fsType = "btrfs";
|
|
|
|
};
|
|
|
|
|
|
|
|
"/boot" = {
|
|
|
|
device = "/dev/disk/by-label/NIXBOOT";
|
|
|
|
fsType = "vfat";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
zramSwap.enable = true;
|
|
|
|
|
|
|
|
hardware.cpu.amd.updateMicrocode = config.hardware.enableRedistributableFirmware;
|
|
|
|
}
|