gpu/amd: Remove loadInInitrd
option
Option is now in nixpkgs under `hardware.amdgpu.initrd.enable` as of NixOS/nixpkgs@6a0b6a6b74
This commit is contained in:
parent
3980e7816c
commit
231274268f
|
@ -26,7 +26,7 @@ in {
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
## Enable the Nvidia card, as well as Prime and Offload:
|
## Enable the Nvidia card, as well as Prime and Offload:
|
||||||
amdgpu.loadInInitrd = true;
|
amdgpu.initrd.enable = lib.mkDefault true;
|
||||||
|
|
||||||
nvidia = {
|
nvidia = {
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
|
|
|
@ -1,24 +1,15 @@
|
||||||
{ config, lib, ... }:
|
{ lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
options.hardware.amdgpu.loadInInitrd = lib.mkEnableOption (lib.mdDoc
|
|
||||||
"loading `amdgpu` kernelModule at stage 1. (Add `amdgpu` to `boot.initrd.kernelModules`)"
|
|
||||||
) // {
|
|
||||||
default = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
imports = [ ../24.05-compat.nix ];
|
imports = [ ../24.05-compat.nix ];
|
||||||
config = lib.mkMerge [
|
config = {
|
||||||
{
|
|
||||||
services.xserver.videoDrivers = lib.mkDefault [ "modesetting" ];
|
services.xserver.videoDrivers = lib.mkDefault [ "modesetting" ];
|
||||||
|
|
||||||
hardware.graphics = {
|
hardware.graphics = {
|
||||||
enable = lib.mkDefault true;
|
enable = lib.mkDefault true;
|
||||||
enable32Bit = lib.mkDefault true;
|
enable32Bit = lib.mkDefault true;
|
||||||
};
|
};
|
||||||
}
|
|
||||||
(lib.mkIf config.hardware.amdgpu.loadInInitrd {
|
hardware.amdgpu.initrd.enable = lib.mkDefault true;
|
||||||
boot.initrd.kernelModules = [ "amdgpu" ];
|
};
|
||||||
})
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
services.xserver.videoDrivers = [ "nvidia" ];
|
services.xserver.videoDrivers = [ "nvidia" ];
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
amdgpu.loadInInitrd = lib.mkDefault false;
|
amdgpu.initrd.enable = false;
|
||||||
|
|
||||||
nvidia = {
|
nvidia = {
|
||||||
modesetting.enable = lib.mkDefault true;
|
modesetting.enable = lib.mkDefault true;
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
services.xserver.videoDrivers = [ "nvidia" ];
|
services.xserver.videoDrivers = [ "nvidia" ];
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
amdgpu.loadInInitrd = lib.mkDefault false;
|
amdgpu.initrd.enable = false;
|
||||||
|
|
||||||
nvidia = {
|
nvidia = {
|
||||||
modesetting.enable = lib.mkDefault true;
|
modesetting.enable = lib.mkDefault true;
|
||||||
|
|
|
@ -18,7 +18,7 @@ in {
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
## Enable the Nvidia card, as well as Prime and Offload:
|
## Enable the Nvidia card, as well as Prime and Offload:
|
||||||
amdgpu.loadInInitrd = true;
|
amdgpu.initrd.enable = true;
|
||||||
|
|
||||||
nvidia = {
|
nvidia = {
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
|
|
Loading…
Reference in a new issue