mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-05-19 13:06:52 +02:00
chore: idols-ai - update kernel, add nvidia-offload command, etc
This commit is contained in:
@@ -41,7 +41,7 @@
|
|||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
|
|
||||||
# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/top-level/linux-kernels.nix
|
# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/top-level/linux-kernels.nix
|
||||||
boot.kernelPackages = pkgs.linuxPackages_6_18; # 6.19 works not well with nvidia driver
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [
|
boot.initrd.availableKernelModules = [
|
||||||
"xhci_pci"
|
"xhci_pci"
|
||||||
|
|||||||
@@ -14,7 +14,10 @@
|
|||||||
# Hybrid graphics with PRIME[integrated GPU (iGPU) + dedicated GPU (dGPU)]
|
# Hybrid graphics with PRIME[integrated GPU (iGPU) + dedicated GPU (dGPU)]
|
||||||
hardware.nvidia.prime = {
|
hardware.nvidia.prime = {
|
||||||
# puts dGPU(Nvidia) to sleep and lets the iGPU handle all tasks by default.
|
# puts dGPU(Nvidia) to sleep and lets the iGPU handle all tasks by default.
|
||||||
offload.enable = true;
|
offload = {
|
||||||
|
enable = true;
|
||||||
|
enableOffloadCmd = true; # generate a nvidia-offload command
|
||||||
|
};
|
||||||
|
|
||||||
intelBusId = "PCI:0@0:2:0";
|
intelBusId = "PCI:0@0:2:0";
|
||||||
nvidiaBusId = "PCI:2@0:0:0";
|
nvidiaBusId = "PCI:2@0:0:0";
|
||||||
@@ -34,10 +37,7 @@
|
|||||||
|
|
||||||
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||||
# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/os-specific/linux/nvidia-x11/default.nix
|
# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/os-specific/linux/nvidia-x11/default.nix
|
||||||
# package = config.boot.kernelPackages.nvidiaPackages.production;
|
package = config.boot.kernelPackages.nvidiaPackages.production;
|
||||||
|
|
||||||
# https://github.com/NixOS/nixpkgs/issues/489947
|
|
||||||
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
|
||||||
|
|
||||||
# required by most wayland compositors!
|
# required by most wayland compositors!
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user