feat: add kernel params for nvidia
This commit is contained in:
parent
b379b6a9ac
commit
73ad96f88e
1 changed files with 13 additions and 2 deletions
|
@ -3,13 +3,24 @@
|
||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
|
# Should not be needed because we set modesetting.enable = true;
|
||||||
|
boot.kernelParams = [
|
||||||
|
"nvidia-drm.modeset=1"
|
||||||
|
"nvidia-drm.fbdev=1"
|
||||||
|
];
|
||||||
|
nixpkgs.config.nvidia.acceptLicense = true;
|
||||||
services.xserver.videoDrivers = ["nvidia"];
|
services.xserver.videoDrivers = ["nvidia"];
|
||||||
|
environment.variables = {
|
||||||
|
GBM_BACKEND = "nvidia-drm";
|
||||||
|
LIBVA_DRIVER_NAME = "nvidia";
|
||||||
|
__GLX_VENDOR_LIBRARY_NAME = "nvidia";
|
||||||
|
};
|
||||||
hardware = {
|
hardware = {
|
||||||
|
enableRedistributableFirmware = true;
|
||||||
|
nvidia-container-toolkit.enable = true;
|
||||||
graphics = {
|
graphics = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [
|
||||||
# TODO:
|
|
||||||
# opencl
|
|
||||||
nvidia-vaapi-driver # hardware acceleration
|
nvidia-vaapi-driver # hardware acceleration
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue