Skip to content
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

kmsdrm: Keep fd around if we can drop master #10915

Merged
merged 1 commit into from
Sep 22, 2024

Conversation

cgutman
Copy link
Collaborator

@cgutman cgutman commented Sep 21, 2024

Description

Modern kernels (v5.8+) allow non-root usage of drmDropMaster(), so we can hold on to our fd after dropping master on it. This fixes populating drm_fd in the KMSDRM SysWMinfo when using Vulkan. Also add a missing error check for open() while we're here.

I'll open a PR for SDL3 if this looks fine.

Modern kernels (v5.8+) allow non-root usage of drmDropMaster(), so
we can hold on to our fd after dropping master on it. This fixes
populating drm_fd in the KMSDRM SysWMinfo when using Vulkan.

Also add a missing error check for open() while we're here.
@slouken slouken merged commit dab4f85 into libsdl-org:SDL2 Sep 22, 2024
40 checks passed
@slouken
Copy link
Collaborator

slouken commented Sep 22, 2024

Looks good, can you make a matching SDL3 PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants