Files
nix-zaneyos/modules/amd-drivers.nix
2024-10-31 20:28:32 +01:00

19 lines
357 B
Nix

{
lib,
pkgs,
config,
...
}:
with lib; let
cfg = config.drivers.amdgpu;
in {
options.drivers.amdgpu = {
enable = mkEnableOption "Enable AMD Drivers";
};
config = mkIf cfg.enable {
systemd.tmpfiles.rules = ["L+ /opt/rocm/hip - - - - ${pkgs.rocmPackages.clr}"];
services.xserver.videoDrivers = ["amdgpu"];
};
}