From c49ee9aec0e00a97db6f48ff8b1d012aa64c7081 Mon Sep 17 00:00:00 2001 From: Schrottkatze Date: Tue, 27 Feb 2024 18:18:08 +0100 Subject: [PATCH] opengl --- hosts/catbook-j/configuration.nix | 16 ++++++++++++++++ hosts/catbook-j/hardware-configuration.nix | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/hosts/catbook-j/configuration.nix b/hosts/catbook-j/configuration.nix index 64b4fa6..9379ded 100644 --- a/hosts/catbook-j/configuration.nix +++ b/hosts/catbook-j/configuration.nix @@ -43,6 +43,22 @@ systemd.services."ModemManager".wants = ["NetworkManager.service"]; systemd.services."ModemManager".wantedBy = ["multi-user.target"]; + environment.variables = { + VDPAU_DRIVER = lib.mkIf config.hardware.opengl.enable (lib.mkDefault "va_gl"); + }; + + hardware.opengl = { + enable = true; + extraPackages = with pkgs; [ + intel-ocl + intel-media-driver + intel-vaapi-driver + intel-compute-runtime + libvdpau-va-gl + mesa.drivers + ]; + }; + programs.wireshark.enable = true; boot.resumeDevice = "/dev/disk/by-uuid/4f9e8afa-f8d7-40bf-b3ea-17e8e8fbb694"; diff --git a/hosts/catbook-j/hardware-configuration.nix b/hosts/catbook-j/hardware-configuration.nix index a692904..6430beb 100644 --- a/hosts/catbook-j/hardware-configuration.nix +++ b/hosts/catbook-j/hardware-configuration.nix @@ -13,7 +13,7 @@ ]; boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"]; - boot.initrd.kernelModules = []; + boot.initrd.kernelModules = ["i915"]; boot.kernelModules = ["kvm-intel"]; boot.extraModulePackages = [];