1
0
Fork 0
mirror of https://github.com/NixOS/nixos-hardware synced 2024-11-23 03:19:42 +01:00

fix: enable enableOffloadCmd in prime.nix only when offload is enabled

This commit is contained in:
Guanran928 2023-09-17 13:52:47 -06:00 committed by mergify[bot]
parent 504893e091
commit d53069def4

View file

@ -1,4 +1,4 @@
{ lib, pkgs, ... }:
{ lib, pkgs, config, ... }:
{
imports = [ ./. ];
@ -6,7 +6,7 @@
hardware.nvidia.prime = {
offload = {
enable = lib.mkOverride 990 true;
enableOffloadCmd = true; # Provides `nvidia-offload` command.
enableOffloadCmd = lib.mkIf config.hardware.nvidia.prime.offload.enable true; # Provides `nvidia-offload` command.
};
# Hardware should specify the bus ID for intel/nvidia devices
};