From 26554b82611f62151b4b1cbb46668607cf9b577f Mon Sep 17 00:00:00 2001 From: Andreas Schaafsma Date: Thu, 26 Mar 2026 04:11:20 +0100 Subject: [PATCH] remove vulkan icd hardcode and enable tearing --- .../drivebystation-nix/hardware/graphics/intel.nix | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/systems/x86_64-linux/drivebystation-nix/hardware/graphics/intel.nix b/systems/x86_64-linux/drivebystation-nix/hardware/graphics/intel.nix index a4117de..94e2e96 100644 --- a/systems/x86_64-linux/drivebystation-nix/hardware/graphics/intel.nix +++ b/systems/x86_64-linux/drivebystation-nix/hardware/graphics/intel.nix @@ -27,7 +27,7 @@ "module_blacklist=nouveau,nvidia,nvidia_drm,nvidia_modeset,nvidia_uvm" ]; services.switcherooControl.enable = true; - environment.variables.VK_ICD_FILENAMES = "/run/opengl-driver/share/vulkan/icd.d/intel_icd.x86_64.json"; + # environment.variables.VK_ICD_FILENAMES = "/run/opengl-driver/share/vulkan/icd.d/intel_icd.x86_64.json"; hardware.intel-gpu-tools.enable = true; hardware.graphics = { enable = true; @@ -53,6 +53,13 @@ "nvidia_uvm" ]; + # Mark Arc B580 as a discrete Intel GPU for switcheroo-control and + # keep runtime PCI power management enabled for the device. + services.udev.extraRules = '' + ACTION=="add|bind", SUBSYSTEM=="pci", ATTR{vendor}=="0x8086", ATTR{device}=="0xe20b", TEST=="power/control", ATTR{power/control}="auto" + SUBSYSTEM=="drm", DRIVERS=="xe", ATTRS{vendor}=="0x8086", ATTRS{device}=="0xe20b", TAG+="switcheroo-discrete-gpu" + ''; + environment.variables = { # Force Intel GPU for all graphics operations KWIN_DRM_DEVICES = "/dev/dri/card0"; @@ -120,4 +127,7 @@ clinfo vulkan-tools ]; + services.xserver.deviceSection = '' + Option "TearFree" "false" + ''; }