Files
NixOS/nixos_24.11_wlin001/system/gpu-amd.nix
2025-04-30 20:47:57 +02:00

40 lines
804 B
Nix

{ config, pkgs, ... }:
{
boot.initrd.kernelModules = [ "amdgpu" ];
# Enable amdgpu
services.xserver = {
videoDrivers = [ "amdgpu" ];
deviceSection = ''Option "TearFree" "true"'';
};
hardware.graphics = {
enable = true;
enable32Bit = true;
};
# Enable AMDVLK and OpenCL
hardware.graphics.extraPackages = with pkgs; [
amdvlk
rocmPackages.clr.icd
];
hardware.graphics.extraPackages32 = with pkgs; [
driversi686Linux.amdvlk
];
environment.systemPackages = with pkgs; [
#lact # Linux AMDGPU Controller
libdrm
vulkan-loader
vulkan-tools
vkbasalt
radeontop
xorg.xf86videoamdgpu
];
#systemd.packages = with pkgs; [ lact ];
#systemd.services.lactd.wantedBy = ["multi-user.target"];
}