wow
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
# https://nixos.wiki/wiki/Nvidia
|
||||
|
||||
#nixpkgs.config.cudaSupport = true; # TODO: TOO SLOW, BREAKS
|
||||
#nixpkgs.config.nvidiaSupport = true; # TODO: used only by zenith
|
||||
#nixpkgs.config.nvidiaSupport = true; # TODO: slow? used only by zenith
|
||||
nixpkgs.config.allowUnfreePredicate = pkg: lib.any (x: x) [
|
||||
(lib.hasInfix "nvidia" (lib.toLower (lib.getName pkg)))
|
||||
(lib.hasInfix "cuda" (lib.toLower (lib.getName pkg)))
|
||||
@@ -21,12 +21,11 @@
|
||||
libvdpau-va-gl
|
||||
];
|
||||
|
||||
hardware.nvidia.modesetting.enable = true; # needed for most wayland compositors
|
||||
hardware.nvidia.modesetting.enable = lib.mkDefault true; # needed for most wayland compositors
|
||||
hardware.nvidia.nvidiaSettings = true;
|
||||
#hardware.nvidia.open = true; # open source version of kernel module, only on driver 515.43.04+
|
||||
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.latest;
|
||||
#hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
#hardware.nvidia.powerManagement.enable = true; # Fix graphical corruption on suspend/resume
|
||||
#hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.latest; # only do this per-host
|
||||
hardware.nvidia.powerManagement.enable = true; # Fix graphical corruption on suspend/resume
|
||||
|
||||
# add this to the host in question:
|
||||
#hardware.nvidia.prime = {
|
||||
@@ -40,7 +39,7 @@
|
||||
environment.systemPackages = with pkgs; ([
|
||||
nvtop-nvidia
|
||||
|
||||
] ++ lib.optional config.hardware.nvidia.prime.offload.enable [
|
||||
] ++ lib.optionals config.hardware.nvidia.prime.offload.enable [
|
||||
(writeShellScriptBin "prime-run" ''
|
||||
export __NV_PRIME_RENDER_OFFLOAD=1
|
||||
export __NV_PRIME_RENDER_OFFLOAD_PROVIDER=NVIDIA-G0
|
||||
|
||||
Reference in New Issue
Block a user