nixos-apple-silicon
nixos-apple-silicon copied to clipboard
remove mesa-asahi-edge
Since mesa 25.1, support for asahi is enabled by default. This means, the nixpkgs mesa is sufficient and we don't need any custom mesa, or methods to replace it.
In addition to the now ineffective hardware.asahi.useExperimentalGPUDriver option, this also removes the hardware.asahi.experimentalGPUInstallMode option, which was already deprecated before.
Are we ready to say goodbye to this? I think Fedora is continuing to keep the custom Mesa around for future development, but the upstream Mesa enablement allows compatibility in VMs etc.
I think it would be better to fix it.
I agree with @tpwrules until fedora switches we shouldn't either. They clearly still think diverging from upstream is worth it.
Gentoo for example only plans to keep mesa around in their overlay until virglrenderer is fixed too.
I'm not entirely what/why Fedora is planning to do (maybe it needs to be orchestrated more carefully there?), but I'd assume in a few months from now things will just end up in mainline mesa, and their custom mesa package will disappear too.
I'm happy to keep this PR open for a while until the dust has settled.
This would immediately break stable which would be really unfortunate so let's not. The fix turns out to be simple, @wistfulbrick 's fix appears right.
On the other hand, the Asahi Linux distro guidelines do not call out Asahi's Mesa fork as needing to be packaged so perhaps we can drop this sooner than I thought.
According to Conan Kudo on Matrix, the next Fedora version will switch to upstream mesa (and Rawhide has already made the switch). However, this did break the emulation stack as mentioned above. It might be best to hold out as @flokli suggested until the dust settles.
I think the virglrenderer MR is at https://gitlab.freedesktop.org/virgl/virglrenderer/-/merge_requests/1527.
Now that Mesa 25.2 has been released with Asahi virtio support enabled, and Fedora Asahi is moving towards using upstream, I think it's time for this to be included.
Mesa 25.2 has landed in nixpkgs-unstable, so I think that this can be merged alongside a flake inputs update.
Mesa 25.2 has landed in
nixpkgs-unstable, so I think that this can be merged alongside a flake inputs update.
Is this included in the pin at https://github.com/nix-community/nixos-apple-silicon/pull/330?
I think it just got barely missed. We need to do a release both for stable and unstable first though. I am preparing those now.
Rebased, and inputs.nixpkgs now has mesa 25.2.0 in there.
I still need to test this.
Is this dependent upon the kernel upgrade? Would prefer to keep that as a separate PR.
Is this dependent upon the kernel upgrade? Would prefer to keep that as a separate PR.
No, the switch to the uapi that was also upstreamed happened a while ago the kernel is already up to date enough. I'm just stupid and pushed these commits too while rebasing, will update 😆
Edit: done
This PR works for me.
What is this drafted on? I imagine it would fix #338 . If we need a nixpkgs update, please put that as the first commit. I am happy to merge both in the same PR.
What is this drafted on? I imagine it would fix #338 . If we need a nixpkgs update, please put that as the first commit. I am happy to merge both in the same PR.
mesa 25.2.0 is in our nixpkgs pin, and this has been sufficiently tested. undrafting.
Thanks, will review tonight if you are waiting on me.
To be fair, I tested with 6.15.8-asahi, not asahi-6.14.8-1, but I assume there's not been a ton of GPU driver changes there, as the UAPI is stable now.
Just to clarify, you want the mkRemovedOptionModule for apple-silicon-support/packages/mesa-asahi-edge/default.nix correct?
I added the mkRemovedOptionModule for the two removed options, and removed the mesa version string from the uefi-standalone.md file, PTAL.
Hi, just to let you know that I tried this PR on my m2 air. And for me it looks broken. I spot it quickly just opening a youtube video. Its laggy.
Hi, just to let you know that I tried this PR on my m2 air. And for me it looks broken. I spot it quickly just opening a youtube video. Its laggy.
That is probably the known Hyprland OpenGL bug with Mesa 25.2, see here.
Hi, just to let you know that I tried this PR on my m2 air. And for me it looks broken. I spot it quickly just opening a youtube video. Its laggy.
That is probably the known Hyprland OpenGL bug with Mesa 25.2, see here.
I'm using sway now, not hyperland anymore.
Hi, just to let you know that I tried this PR on my m2 air. And for me it looks broken. I spot it quickly just opening a youtube video. Its laggy.
That is probably the known Hyprland OpenGL bug with Mesa 25.2, see here.
I'm using sway now, not hyperland anymore.
And it's still an issue, or not an issue anymore?
Hi, just to let you know that I tried this PR on my m2 air. And for me it looks broken. I spot it quickly just opening a youtube video. Its laggy.
That is probably the known Hyprland OpenGL bug with Mesa 25.2, see here.
I'm using sway now, not hyperland anymore.
And it's still an issue, or not an issue anymore?
I sadly dont know what is the root cause, mesa related for sure, but yes, its not usuable anymore for me it this get merged as this. My previous reply was maybe not clear. I was an hyprland user, but I run sway since long time already now. I dont install sway just now.
I use the Hyprland patches suggested by another user in #340 with mesa 25.2, but it still runs on llvmpipe for me too. I'm not sure why it doesn't work in my case or what I'm doing wrong.
These patches are the ones from a Hyprland PR that is supposed to fix this problem.
Can it be we need both last kernel and mesa to get all thing working ? You said previously @flokli you test only on last kernel true ? Your other PR ?
Can it be we need both last kernel and mesa to get all thing working ? You said previously @flokli you test only on last kernel true ? Your other PR ?
I tried using #326 to update kernel, but that didn't work either. To be clear I didn't use this PR, I just set useExperimentalGPUDriver = false, which should have the same effect.
Okay just upgraded my nixpkgs (2025-08-19) in my nixos configuration on a branch with this patch applied and now I'm suddenly in llvmpipe even though I'm on 25.2 and on GNOME (setting hardware.graphics.enable explicitly doesn't have an effect)
relevant vulkaninfo output:
Device Properties and Extensions:
=================================
GPU0:
VkPhysicalDeviceProperties:
---------------------------
apiVersion = 1.4.318 (4211006)
driverVersion = 25.2.0 (104865792)
vendorID = 0x10005
deviceID = 0x0000
deviceType = PHYSICAL_DEVICE_TYPE_CPU
deviceName = llvmpipe (LLVM 19.1.7, 128 bits)
pipelineCacheUUID = 32352e32-2e30-6161-6161-616161616161
I don't know if this is a kernel issue or an upstream (nixpkgs) mesa regression.