-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
drm: check syncobj timeline support before advertising protocol #11117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
this MR is based on some old rev, needs to be rebased on top of main, that's first. Second - Asahi and Apple Silicon support explicit sync - just not on the display node, and Tom is working on that in #11087 |
Prevents crashes on systems where DRM driver lacks syncobj timeline support (e.g., Apple Silicon with Honeykrisp driver). Applications like Zed and WezTerm would crash with 'Timeline failed importing' when trying to use explicit sync. Fixes hyprwm#8158 hyprwm#8803
210b366
to
09b0fbc
Compare
Rebased and retested |
2e5aa2c
to
09b0fbc
Compare
Fixed - moved the capability check to init and removed the duplicate functions. Retested again - works. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rest lgtm
c-f failed, run c-f pls |
Describe your PR, what does it fix/add?
Fixes crashes in Vulkan applications (Zed, WezTerm, etc.) on systems where the DRM driver doesn't support syncobj timelines, particularly Apple Silicon devices running Asahi Linux with the Honeykrisp driver.
The issue was that Hyprland advertised the
linux-drm-syncobj-v1
protocol regardless of hardware support. When applications attempted to use explicit sync, they would crash with "Timeline failed importing" errors.This PR adds
DRM_CAP_SYNCOBJ_TIMELINE
capability checking at two levels:Is there anything you want to mention? (unchecked code, possible bugs, found problems, breaking compatibility, etc.)
No breaking compatibility - this only prevents advertising a protocol when the underlying hardware doesn't support it. Applications gracefully fall back to implicit sync when explicit sync isn't available.
Is it ready for merging, or does it need work?
Ready for merging. Tested on Fedora Asahi Remix with Apple M1 Pro. Applications that previously crashed now start successfully and run normally.