Bug 456089 - Kwin endlessly emits "Could not create drm framebuffer!" warning on fullscreen Firefox video on secondary GPU
Summary: Kwin endlessly emits "Could not create drm framebuffer!" warning on fullscree...
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.25.2
Platform: Other Linux
: NOR minor
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-06-28 16:27 UTC by Schlaefer
Modified: 2022-06-29 10:03 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Schlaefer 2022-06-28 16:27:53 UTC
STEPS TO REPRODUCE
1. Dual GPU setup: AMD discrete, main GPU and Intel integrated, secondary iGPU
2. Start Firefox on secondary iGPU (in my case "DRI_PRIME=1 firefox")
3. Play a video on e.g. Youtube and enter fullscreen mode for the video

OBSERVED RESULT

The system-log  gets flooded with "kwin_wayland_drm: Could not create drm framebuffer! Invalid argument" multiple times per second.

EXPECTED RESULT

The system-log shouldn't be flooded with messages.

SOFTWARE/OS VERSIONS
Firefox 102 in Wayland mode
Operating System: EndeavourOS
KDE Plasma Version: 5.25.2
KDE Frameworks Version: 5.95.0
Qt Version: 5.15.5
Kernel Version: 5.18.7-zen1-1-zen (64-bit)
Graphics Platform: Wayland
Processors: 12 × 11th Gen Intel® Core™ i5-11400 @ 2.60GHz
Graphics Processor: AMD Radeon RX 5500 XT

ADDITIONAL INFORMATION

The issue started after the update from plasma 5.24 to 5.25. 

I toyed a little bit with the code and "drmModeAddFB2WithModifiers()" returns "-22" in my case [1].

[1] https://invent.kde.org/plasma/kwin/-/blob/34e14bb1eefbaed1a6018108677ef2619e02330e/src/backends/drm/drm_buffer.cpp#L143
Comment 1 Bug Janitor Service 2022-06-28 21:23:58 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/2586
Comment 2 Zamundaaa 2022-06-29 09:42:14 UTC
Git commit ef97158f9633fb1fc6489e540b273e533e861004 by Xaver Hugl.
Committed on 29/06/2022 at 07:59.
Pushed by zamundaaa into branch 'master'.

backends/drm: suppress logging for direct scanout

M  +0    -1    src/backends/drm/drm_buffer.cpp
M  +3    -0    src/backends/drm/drm_lease_egl_gbm_layer.cpp
M  +13   -0    src/backends/drm/drm_qpainter_layer.cpp
M  +20   -4    src/backends/drm/egl_gbm_layer_surface.cpp

https://invent.kde.org/plasma/kwin/commit/ef97158f9633fb1fc6489e540b273e533e861004
Comment 3 Zamundaaa 2022-06-29 10:03:07 UTC
Git commit e10ecec362bd0bb39d10ad17d4ac6e4f921254db by Xaver Hugl.
Committed on 29/06/2022 at 10:03.
Pushed by zamundaaa into branch 'Plasma/5.25'.

backends/drm: suppress logging for direct scanout


(cherry picked from commit ef97158f9633fb1fc6489e540b273e533e861004)

M  +0    -1    src/backends/drm/drm_buffer.cpp
M  +3    -0    src/backends/drm/drm_lease_egl_gbm_layer.cpp
M  +13   -0    src/backends/drm/drm_qpainter_layer.cpp
M  +20   -4    src/backends/drm/egl_gbm_layer_surface.cpp

https://invent.kde.org/plasma/kwin/commit/e10ecec362bd0bb39d10ad17d4ac6e4f921254db