diff --git a/flake.lock b/flake.lock index ac9f9ce..0d3256f 100644 --- a/flake.lock +++ b/flake.lock @@ -56,11 +56,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1761672384, - "narHash": "sha256-o9KF3DJL7g7iYMZq9SWgfS1BFlNbsm6xplRjVlOCkXI=", + "lastModified": 1763966396, + "narHash": "sha256-6eeL1YPcY1MV3DDStIDIdy/zZCDKgHdkCmsrLJFiZf0=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "08dacfca559e1d7da38f3cf05f1f45ee9bfd213c", + "rev": "5ae3b07d8d6527c42f17c876e404993199144b6a", "type": "github" }, "original": { diff --git a/nixosModules/testvm.nix b/nixosModules/testvm.nix index 6b0a075..a70f41a 100644 --- a/nixosModules/testvm.nix +++ b/nixosModules/testvm.nix @@ -16,7 +16,7 @@ pkgs.xorg.xeyes pkgs.xterm # pkgs.vkquake # build broken: Program 'spirv-remap' not found - pkgs.veloren + # pkgs.veloren # broken after update? pkgs.kdePackages.kate pkgs.adwaita-icon-theme pkgs.amberol diff --git a/packages/mesa/default.nix b/packages/mesa/default.nix index 51c2d79..d76f1b5 100644 --- a/packages/mesa/default.nix +++ b/packages/mesa/default.nix @@ -1,16 +1,10 @@ -{ mesa, lib }: +{ mesa, lib, stdenv }: (mesa.override { - vulkanDrivers = [ - "amd" - "intel" - "microsoft-experimental" # removing this breaks the build - "nouveau" - "swrast" - "virtio" - "gfxstream" # probably not going to use this though - ]; + # nothing currently }).overrideAttrs (new: old: { - mesonFlags = old.mesonFlags ++ [ (lib.mesonBool "amdgpu-virtio" true) ]; - patches = old.patches ++ [ ../../radvmmio.patch ]; # already merged to git + mesonFlags = old.mesonFlags ++ + lib.optionals stdenv.hostPlatform.isx86_64 [ (lib.mesonBool "amdgpu-virtio" true) ]; + # not that amdgpu can't be found on aarch64 but let's avoid rebuilds for now + # patches = old.patches ++ [ ]; }) diff --git a/radvmmio.patch b/radvmmio.patch deleted file mode 100644 index c3ff0bf..0000000 --- a/radvmmio.patch +++ /dev/null @@ -1,42 +0,0 @@ -From c2fd030644cf2074f9d2ffd155839b2e943473d0 Mon Sep 17 00:00:00 2001 -From: Val Packett -Date: Wed, 10 Sep 2025 15:44:41 -0300 -Subject: [PATCH] radv: detect platform:virtio-mmio devices for virtgpu native - context - -VirtIO devices can be configured as platform devices instead of PCI, -which is especially common in microVM projects like libkrun. - -Let's allow RADV to probe MMIO virtgpu devices. - -Signed-off-by: Val Packett ---- - src/amd/vulkan/radv_physical_device.c | 7 ++++--- - 1 file changed, 4 insertions(+), 3 deletions(-) - -diff --git a/src/amd/vulkan/radv_physical_device.c b/src/amd/vulkan/radv_physical_device.c -index 07b5b000b3ae..cd6f4c3488a1 100644 ---- a/src/amd/vulkan/radv_physical_device.c -+++ b/src/amd/vulkan/radv_physical_device.c -@@ -2507,14 +2507,15 @@ create_drm_physical_device(struct vk_instance *vk_instance, struct _drmDevice *d - #ifndef _WIN32 - bool supported_device = false; - -- if (!(device->available_nodes & (1 << DRM_NODE_RENDER)) || device->bustype != DRM_BUS_PCI) -+ if (!(device->available_nodes & (1 << DRM_NODE_RENDER))) - return VK_ERROR_INCOMPATIBLE_DRIVER; - - #ifdef HAVE_AMDGPU_VIRTIO -- supported_device |= device->deviceinfo.pci->vendor_id == VIRTGPU_PCI_VENDOR_ID; -+ supported_device |= device->bustype == DRM_BUS_PCI && device->deviceinfo.pci->vendor_id == VIRTGPU_PCI_VENDOR_ID; -+ supported_device |= device->bustype == DRM_BUS_PLATFORM; /* virtio-mmio */ - #endif - -- supported_device |= device->deviceinfo.pci->vendor_id == ATI_VENDOR_ID; -+ supported_device |= device->bustype == DRM_BUS_PCI && device->deviceinfo.pci->vendor_id == ATI_VENDOR_ID; - - if (!supported_device) - return VK_ERROR_INCOMPATIBLE_DRIVER; --- -2.50.1 -