This repository has been archived by the owner on Nov 1, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 343
drm: add fallback drmModeAddFB for drivers which do not support drmModeAddFB2 #2569
Merged
emersion
merged 1 commit into
swaywm:master
from
kaniini:feature/drm-mode-add-fb-fallback
Dec 28, 2020
Merged
drm: add fallback drmModeAddFB for drivers which do not support drmModeAddFB2 #2569
emersion
merged 1 commit into
swaywm:master
from
kaniini:feature/drm-mode-add-fb-fallback
Dec 28, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
emersion
reviewed
Dec 23, 2020
kaniini
force-pushed
the
feature/drm-mode-add-fb-fallback
branch
2 times, most recently
from
December 23, 2020 19:24
8ce8e13
to
4691870
Compare
emersion
reviewed
Dec 23, 2020
kaniini
force-pushed
the
feature/drm-mode-add-fb-fallback
branch
from
December 23, 2020 20:51
4691870
to
cc26cc4
Compare
emersion
suggested changes
Dec 24, 2020
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.
LGTM apart from these minor comments!
kaniini
force-pushed
the
feature/drm-mode-add-fb-fallback
branch
from
December 24, 2020 12:35
cc26cc4
to
03e0578
Compare
All of these revisions should now be incorporated :) |
…deAddFB2 This makes wlroots able to run on some big-endian machines like G4 and G5 systems with ATI Radeon 7500 AGP graphics.
emersion
force-pushed
the
feature/drm-mode-add-fb-fallback
branch
from
December 28, 2020 13:10
03e0578
to
6298742
Compare
emersion
approved these changes
Dec 28, 2020
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.
Thanks!
emersion
added a commit
to emersion/wlroots
that referenced
this pull request
Apr 23, 2021
The previous code would always print "falling back to legacy method", even if the format wasn't ARGB8888. Drop get_fb_for_bo_legacy, since the code can just be inlined without hurting readability. Ideally we should only fallback to drmModeAddFB if the error code indicates the BE failure, but the original PR [1] doesn't say what error code is returned by the kernel. [1]: swaywm#2569
kennylevinsen
pushed a commit
that referenced
this pull request
Apr 26, 2021
The previous code would always print "falling back to legacy method", even if the format wasn't ARGB8888. Drop get_fb_for_bo_legacy, since the code can just be inlined without hurting readability. Ideally we should only fallback to drmModeAddFB if the error code indicates the BE failure, but the original PR [1] doesn't say what error code is returned by the kernel. [1]: #2569
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request implements a fallback
get_fb_for_bo_legacy
function which uses the legacydrmAddModeFB
function to set up the framebuffer.This is based on the logic in xf86-video-modesetting, and allows both Sway and my own compositor to run on older cards which otherwise support the necessary features for Wayland to function. Tested on a machine with ATI Radeon 7500 AGP graphics.