Description
Shawn Starr
2021-02-09 21:04:30 UTC
This works on X11, right? Yes, X11 its fine. The external displays in laptops are often (or rather were, in newer laptops it's AFAIK different) connected to the dedicated GPU, so it'll most likely work with 5.21 Seeing im on 5.20.90, 5.21 will not fix issue since it is 5.21 beta :) Ah, sorry, please attach ~/.local/share/sddm/wayland-session.log I will later this week provide the log. Ill provide log tonight I don't see this log file in my $HOME or anywhere? Created attachment 136070 [details]
Wayland Errors/Session log from SDDM
I've found the log here it is attached
I should note, with latest Fedora Plasma: plasma-workspace-5.21.0-1.fc35.x86_64 Kscreen now does see two displays but the DisplayPort screen does not turn on, it remains powered off Even though Kscreen reports correct resolution, refresh rates. So some progress here. I notice this in the log: kwin_wayland_drm: Could not find a fitting mode with size=2560x1440 and refresh rate 144000 for output 815efd90c2 kwin_wayland_drm: Could not find a fitting mode with size=1920x1080 and refresh rate 60012 for output 3a7a96dd23 Where: 815efd90c2 (/dev/dri/card0) == Integrated GPU: Intel HD Graphics 4600 (HSW GT2) 3a7a96dd23 (/dev/dri/card1) == Dedicated GPU: AMD FirePro M6100 (AMD Radeon HD 8950) Kwin's DRM code seems correct, but not correct in failing to determine the display can handle these resolutions. When it can in X... seems like a bug The Laptop display lights up: kwin_wayland_drm: For new output use mode 1920x1080 1920 1080 kwin_wayland_drm: Initialized primary plane 31 on CRTC 45 kwin_core: Adding mode 1: QSize(1920, 1080) [60012] The "can't find fitting mode" warning just means that on KWin can't find the intial mode it wants, it just falls back to the first mode. The relevant error is drmModeAddFB failed It's possible that part of the problem is driver or hardware support - I'll find out how to get relevant information for that. hmm, well since it works with Xorg, the driver seems ok, both the DRM kernel, DRI side at least. What I mean is that there's probably some edge-case or assumption about the driver that we're not handling correctly. Are you using the amdgpu or radeon kernel driver? IIRC for a few of those old cards radeon is still the default. If that affects your card, could you try what happens with amdgpu? I use amdgpu, disabled radeon for CIK. A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/756 Does the patch fix the problem (or at least change anything)? In theory the two function calls should do the same but it's worth a try I need to refresh my KDE build outside of using Fedora RPMs, ill gget back to you on this, Or if I can apply this patch as part of building the Fedora RPM.. might try that first Well I got built, it is failing attached is wayland-errors log. Created attachment 136708 [details]
Wayland Error log #2
Wayland Error log #2
Can you get a backtrace of the crash? And can you reproduce it on master? This was from master branch, in this case how can I get a gdb crash dump? Are you on IRC? :) KWin debugging isntructions: echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope sudo gdb -pid $(pidof kwin_wayland) -batch -ex "set logging file kwin_wayland.gdb" -ex "set logging on" -ex "continue" -ex "thread apply all backtrace" -ex "quit" Except im not sure how do I wrap kwin_wayland to use gdb via SDDM via my /usr/share/wayland-sessions/plasmawayland-dev.desktop? Since I get no display while kwin crashes on start. Log one is from 5.21, and log two is from my merge request. As I undertand it, 5.21 doesn't show anything and my merge request makes the session crash? It would be interesting if master crashes as well. You can get the backtrace by using coredumpctl (if the coredump isn't truncated) or by using gdb over ssh I tried using: gdb -batch -ex "set logging file kwin_wayland.gdb" -ex "set logging on" -ex "continue" -ex "thread apply all backtrace"-ex quit --args kwin_wayland --libinput --drm While that worked, oddly the DisplayPort turned *on* though froze.. This is difficult to debug if I can't reproduce this with SDDM -> plasmastart --> kwin. Will coredumpctl work even with this? The wiki says: "Warning The kwin_wayland process is not dumpable, which means coredumpctl is unable to fetch a full backtrace, rendering only truncated core dumps. Those are still useful, but if possible, SSH into your session and attach GDB directly." So, If you can provide some step for me to try to debug this consistently. GDB stack dump $ sudo gdb --core core.kwin_wayland.1000.55d0822d350d434bb3a76b384eae7800.1445.1615920868000000 GNU gdb (GDB) Fedora 10.1-14.fc35 Copyright (C) 2020 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-redhat-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <https://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word". warning: Can't open file /memfd:JSGCHeap:QtQml (deleted) during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file /memfd:JSVMStack:QtQml (deleted) during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file /memfd:unknown-usage:QtQml (deleted) during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing warning: Can't open file anon_inode:i915.gem which was expanded to anon_inode:i915.gem during file-backed mapping note processing [New LWP 1445] [New LWP 1446] [New LWP 1452] [New LWP 1459] [New LWP 1448] [New LWP 1462] [New LWP 1447] [New LWP 1468] [New LWP 1461] [New LWP 1453] [New LWP 1465] [New LWP 1451] [New LWP 1464] [New LWP 1454] [New LWP 1455] [New LWP 1467] [New LWP 1458] [New LWP 1470] [New LWP 1475] [New LWP 1460] [New LWP 1477] [New LWP 1463] [New LWP 1472] [New LWP 1457] [New LWP 1469] [New LWP 1466] Reading symbols from /usr/lib64/libffi.so.6.0.2... Reading symbols from /usr/lib/debug/usr/lib64/libffi.so.6.0.2-3.1-28.fc34.x86_64.debug... warning: Ignoring non-absolute filename: <linux-vdso.so.1> Missing separate debuginfo for linux-vdso.so.1 Try: dnf --enablerepo='*debug*' install /usr/lib/debug/.build-id/0c/f00d2ae4f266ffbda56d7c5c61fcf64c5c439a Warning: couldn't activate thread debugging using libthread_db: Cannot find new threads: generic error warning: File "/usr/lib64/libthread_db-1.0.so" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load:/usr/lib/golang/src/runtime/runtime-gdb.py". To enable execution of this file add Missing separate debuginfos, use: dnf debuginfo-install kf5-frameworkintegration-libs-5.79.0-2.fc34.x86_64 kf5-kactivities-5.79.0-2.fc34.x86_64 kf5-karchive-5.79.0-2.fc34.x86_64 kf5-kbookmarks-5.79.0-2.fc34.x86_64 kf5-kdbusaddons-5.79.0-2.fc34.x86_64 kf5-kdeclarative-5.79.0-2.fc34.x86_64 kf5-kio-core-libs-5.79.0-3.fc34.x86_64 kf5-kio-file-widgets-5.79.0-3.fc34.x86_64 kf5-kio-gui-5.79.0-3.fc34.x86_64 kf5-kio-widgets-libs-5.79.0-3.fc34.x86_64 kf5-kxmlgui-5.79.0-2.fc34.x86_64 kf5-plasma-5.79.0-2.fc34.x86_64 libacl-2.2.53-10.fc34.x86_64 libattr-2.4.48-11.fc34.x86_64 libselinux-3.2-0.rc2.1.fc34.x86_64 libxkbcommon-1.0.3-2.fc34.x86_64 ncurses-libs-6.2-4.20200222.fc34.x86_64 qt5-qtsvg-5.15.2-3.fc34.x86_64 systemd-libs-248~rc2-3.fc35.x86_64 --Type <RET> for more, q to quit, c to continue without paging-- add-auto-load-safe-path /usr/lib64/libthread_db-1.0.so line to your configuration file "/root/.gdbinit". To completely disable this security protection add set auto-load safe-path / line to your configuration file "/root/.gdbinit". For more information about this security protection see the "Auto-loading safe path" section in the GDB manual. E.g., run from the shell: info "(gdb)Auto-loading safe path" warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available. [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". Core was generated by `kwin_wayland --wayland_fd 4 --xwayland /usr/libexec/startplasma-waylandsession'. Program terminated with signal SIGSEGV, Segmentation fault. #0 0x00007fcb6377bedf in gbm_bo_destroy (bo=0x55c54b914380) at ../src/gbm/main/gbm.c:445 445 bo->gbm->bo_destroy(bo); [Current thread is 1 (Thread 0x7fcb71a2ae00 (LWP 1445))] (gdb) bt #0 0x00007fcb6377bedf in gbm_bo_destroy (bo=0x55c54b914380) at ../src/gbm/main/gbm.c:445 #1 0x00007fcb637f1d9e in KWin::EglGbmBackend::renderFramebufferToSurface(KWin::EglGbmBackend::Output&) (this=this@entry=0x55c54accae00, output=...) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/plugins/platforms/drm/egl_gbm_backend.cpp:457 #2 0x00007fcb637f848b in KWin::EglGbmBackend::endFrame(int, QRegion const&, QRegion const&) (this=0x55c54accae00, screenId=<optimized out>, renderedRegion=<optimized out>, damagedRegion=...) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/plugins/platforms/drm/egl_gbm_backend.cpp:676 #3 0x00007fcb637f1671 in KWin::EglMultiBackend::endFrame(int, QRegion const&, QRegion const&) (this=<optimized out>, screenId=<optimized out>, damage=..., damagedRegion=...) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/plugins/platforms/drm/egl_multi_backend.cpp:72 #4 0x00007fcb61c26ee2 in KWin::SceneOpenGL::paint(int, QRegion const&, QList<KWin::Toplevel*> const&, KWin::RenderLoop*) (renderLoop=<optimized out>, toplevels=<optimized out>, damage=<optimized out>, screenId=1, this=0x55c54aebba00) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/plugins/scenes/opengl/scene_opengl.cpp:699 #5 KWin::SceneOpenGL::paint(int, QRegion const&, QList<KWin::Toplevel*> const&, KWin::RenderLoop*) (this=0x55c54aebba00, screenId=1, damage=<optimized out>, toplevels=<optimized out>, renderLoop=<optimized out>) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/plugins/scenes/opengl/scene_opengl.cpp:605 #6 0x00007fcb780eac15 in KWin::Compositor::handleFrameRequested(KWin::RenderLoop*) (renderLoop=0x55c54ac87fb0, this=<optimized out>) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/composite.cpp:665 #7 KWin::Compositor::handleFrameRequested(KWin::RenderLoop*) (this=<optimized out>, renderLoop=0x55c54ac87fb0) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/composite.cpp:589 #8 0x00007fcb785c74b0 in QtPrivate::QSlotObjectBase::call(QObject*, void**) (a=0x7fffcb2ca230, r=<optimized out>, this=0x55c54b6b60d0) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:398 #9 doActivate<false>(QObject*, int, void**) (sender=0x55c54ac87fb0, signal_index=5, argv=0x7fffcb2ca230) at kernel/qobject.cpp:3886 #10 0x00007fcb785c19e7 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (sender=<optimized out>, m=m@entry=0x7fcb782fe560 <KWin::RenderLoop::staticMetaObject>, local_signal_index=local_signal_index@entry=2, argv=argv@entry=0x7fffcb2ca230) at kernel/qobject.cpp:3946 #11 0x00007fcb780abe26 in KWin::RenderLoop::frameRequested(KWin::RenderLoop*) (this=<optimized out>, _t1=<optimized out>) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/x86_64-redhat-linux-gnu/src/kwin_autogen/EWIEGA46WW/moc_renderloop.cpp:193 #12 0x00007fcb78176c17 in KWin::RenderLoopPrivate::dispatch() (this=0x55c54acaf2b0) at /usr/src/debug/kwin-5.22.0-1.fc35.x86_64/src/renderloop.cpp:143 #13 0x00007fcb785c74b0 in QtPrivate::QSlotObjectBase::call(QObject*, void**) (a=0x7fffcb2ca350, r=<optimized out>, this=0x55c54abf8c20) at ../../include/QtCore/../../src/corelib/kernel/qobjectdefs_impl.h:398 #14 doActivate<false>(QObject*, int, void**) (sender=0x55c54acaf2c8, signal_index=3, argv=0x7fffcb2ca350) at kernel/qobject.cpp:3886 #15 0x00007fcb785c19e7 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (sender=<optimized out>, m=m@entry=0x7fcb7885c580 <QTimer::staticMetaObject>, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffcb2ca350) at kernel/qobject.cpp:3946 #16 0x00007fcb785ca5ae in QTimer::timeout(QTimer::QPrivateSignal) (this=<optimized out>, _t1=...) at .moc/moc_qtimer.cpp:205 #17 0x00007fcb785be21f in QObject::event(QEvent*) (this=0x55c54acaf2c8, e=0x7fffcb2ca4a0) at kernel/qobject.cpp:1336 #18 0x00007fcb775c8e73 in QApplicationPrivate::notify_helper(QObject*, QEvent*) (this=<optimized out>, receiver=0x55c54acaf2c8, e=0x7fffcb2ca4a0) at kernel/qapplication.cpp:3632 #19 0x00007fcb78596f48 in QCoreApplication::notifyInternal2(QObject*, QEvent*) (receiver=0x55c54acaf2c8, event=0x7fffcb2ca4a0) at kernel/qcoreapplication.cpp:1063 #20 0x00007fcb785e29e3 in QTimerInfoList::activateTimers() (this=this@entry=0x55c54ab34c98) at kernel/qtimerinfo_unix.cpp:643 #21 0x00007fcb785dfe60 in QEventDispatcherUNIXPrivate::activateTimers() (this=this@entry=0x55c54ab34c10) at kernel/qeventdispatcher_unix.cpp:249 #22 0x00007fcb785e0ee0 in QEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (this=<optimized out>, flags=...) at kernel/qeventdispatcher_unix.cpp:516 #23 0x000055c549976621 in () --Type <RET> for more, q to quit, c to continue without paging-- #24 0x000055c54abf1dac in () #25 0x0000000000000024 in () #26 0x000055c54abf1d50 in () #27 0x00007fcb785959b2 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (this=this@entry=0x7fffcb2ca620, flags=..., flags@entry=...) at ../../include/QtCore/../../src/corelib/global/qflags.h:69 #28 0x00007fcb7859d544 in QCoreApplication::exec() () at ../../include/QtCore/../../src/corelib/global/qflags.h:121 #29 0x000055c5499223f4 in () #30 0x0000000000000000 in () Created attachment 136749 [details]
Stack dump
Stack dump
Created attachment 136754 [details]
Wayland Session Errors from multiple kwin spawn attempts by SDDM
Wayland Session Errors from multiple kwin spawn attempts by SDDM
Git commit 6569bf80c37ea46e7507fac17b9f1162b9a9978e by Xaver Hugl. Committed on 18/03/2021 at 14:22. Pushed by zamundaaa into branch 'master'. EglGbmBackend: use output reference M +2 -2 src/plugins/platforms/drm/egl_gbm_backend.cpp https://invent.kde.org/plasma/kwin/commit/6569bf80c37ea46e7507fac17b9f1162b9a9978e Will test this commit and report back Test https://invent.kde.org/plasma/kwin/-/merge_requests/756 that's rebased. The crash should be fixed, the behavior of the monitor will most likely not change though Well, the coredump is fixed, and it shows a lot more of the error... Created attachment 136828 [details]
New Wayland Session log
New Wayland Session log
Can you provide that new coredump then? (in addition to the session log) Oh there's no coredump now, systemd coredumpctl shows none. This core issue remains, I just happened to crash kwin before the above commit is already in the master branch. I'll be adding a CPU fallback mode for multi-GPU soon™, that would definitely work. Ideally we can still get it working with hardware acceleration for 5.22 though... Could you check if on master a fullscreen game running through Xwayland and on the dedicated GPU makes the display work? Even if there is no PRIME support for the hardware that should show something. If it does show something, could you then test the same but with the game running on the integrated graphics? Well, its not even a game that works, Plasma/Kscreen doesnt detect the screen. I know that the display doesn't turn on but you should be able to move windows to it on master. Well, right now when i try starting with XWayland via SDDM, it just locks up the screen I can VT switch however.. I will create a new user and see if any .config from KDE is causing XWayland/X11 confusion with Kwin/Kscreen Yes, if I make a new user, XWayland starts only on the Laptop display, I *can* drag windows to the external display. Kscreen does detect this but no display, I do see attempts to power it on then it fails the kernel shows: [ 91.494549] amdgpu: VI should always have 2 performance levels [ 126.275199] [drm] PCIE gen 3 link speeds already enabled [ 126.277690] [drm] PCIE GART of 1024M enabled (table at 0x000000F400000000). [ 126.282206] amdgpu 0000:01:00.0: amdgpu: SRBM_SOFT_RESET=0x00100040 [ 126.449983] [drm] Got external EDID base block and 2 extensions from "edid/Samsung-LC27G7xT.edid.bin" for connector "DP-2" [ 126.510293] [drm] UVD initialized successfully. [ 126.631314] [drm] VCE initialized successfully. [ 132.760379] amdgpu: VI should always have 2 performance levels [ 139.011159] [drm] PCIE gen 3 link speeds already enabled [ 139.012180] [drm] PCIE GART of 1024M enabled (table at 0x000000F400000000). [ 139.014696] amdgpu 0000:01:00.0: amdgpu: SRBM_SOFT_RESET=0x00100040 [ 139.173110] [drm] Got external EDID base block and 2 extensions from "edid/Samsung-LC27G7xT.edid.bin" for connector "DP-2" [ 139.232354] [drm] UVD initialized successfully. [ 139.353376] [drm] VCE initialized successfully. [ 159.485632] amdgpu: VI should always have 2 performance levels [ 182.866884] [drm] PCIE gen 3 link speeds already enabled [ 182.869354] [drm] PCIE GART of 1024M enabled (table at 0x000000F400000000). [ 182.873968] amdgpu 0000:01:00.0: amdgpu: SRBM_SOFT_RESET=0x00100040 [ 183.037980] [drm] Got external EDID base block and 2 extensions from "edid/Samsung-LC27G7xT.edid.bin" for connector "DP-2" [ 183.097016] [drm] UVD initialized successfully. [ 183.218037] [drm] VCE initialized successfully. [ 188.819090] amdgpu: VI should always have 2 performance levels [ 193.681966] [drm] PCIE gen 3 link speeds already enabled [ 193.684447] [drm] PCIE GART of 1024M enabled (table at 0x000000F400000000). [ 193.688981] amdgpu 0000:01:00.0: amdgpu: SRBM_SOFT_RESET=0x00100040 [ 193.853029] [drm] Got external EDID base block and 2 extensions from "edid/Samsung-LC27G7xT.edid.bin" for connector "DP-2" [ 193.913052] [drm] UVD initialized successfully. [ 194.034072] [drm] VCE initialized successfully. [ 194.405045] broken atomic modeset userspace detected, disabling atomic [ 207.167245] amdgpu: [powerplay] failed to send message 146 ret is 0 I even tried disconnecting from my DisplayPort KVM switch, same result, so that eliminates that. If this is a kernel bug, why does this only manifest with XWayland and not X11? Okay now the interesting bit would be if fullscreen apps running through Xwayland make the display work - with direct scanout they bypass the normal multi-GPU mechanism. So just use any game from Steam or install Xonotic or something like that from your distros repo, make it fullscreen and drag the fullscreen window to the not-working display with Meta + Left Click. If I'm right then the display should light up. (In reply to Shawn Starr from comment #43) > If this is a kernel bug, why does this only manifest with Wayland and not > X11? Either X is doing hardware accelerated multi-GPU differently in some way that works or it's using the CPU fallback I will try that in a moment... Does not work. I even tried Wine with League of Legends, moved window to other screen, alt+enter but it moved the full screen to the laptop output. Attached the is the log with League of Legends Created attachment 136854 [details]
kwin Xwayland - wayland-errors.log
kwin Xwayland - wayland-errors.log
Are you sure the game ran on the dedicated GPU? The log suggests to me that it probably wasn't Should be, DRI_PRIME is set, but I'll double check and or enforce if its not. From my Xorg config I have DRI_PRIME=0 OpenGL renderer string: AMD Radeon HD 8950 (BONAIRE, DRM 3.40.0, 5.10.14-200.fc33.x86_64, LLVM 11.1.0) OpenGL core profile version string: 4.6 (Core Profile) Mesa 21.0.0 OpenGL core profile shading language version string: 4.60 When in standard X I don't know how Kwin/KWayland-server handles integrated vs dedicated GPUs here. But if I move the window to the DisplayPort nothing lights up... I tried again, explicitly even set DRI_PRIME to right GPU, attached is new wayland-errors log file. Created attachment 137046 [details]
Kwin Kwayland-server new log
Kwin Kwayland-server new log
I should note when I moved the screen to the DisplayPort, then maximized it was returned to the laptop screen. So it was not allowing it to be displayed on the DisplayPort output which didn't light up. I did see in logs: kwin_wayland_drm: drmModeAddFB2WithModifiers failed! Invalid argument kwin_wayland_drm: drmModeAddFB2 and drmModeAddFB both failed! Invalid argument So, drmModeAddFB2WithModifiers is new... *** Bug 425586 has been marked as a duplicate of this bug. *** *** Bug 435265 has been marked as a duplicate of this bug. *** Can you test if https://invent.kde.org/plasma/kwin/-/merge_requests/832 works? Will compile and report back today Well, something appeared but it was garbage output on the DisplayPort. I had to alt-tab to switch VT then back and then I noticed my laptop display lit up. Attached is log. Created attachment 137423 [details]
Wayland Errors Log - with work/zamundaaa/dumb-import branch for kwin
Wayland Errors Log - with work/zamundaaa/dumb-import branch for kwin
Results: In the first log, I created a new user - Started Plasma Wayland session, Laptop screen and DisplayPort didnt turn on, VT switched, the DisplayPort turned on saw an X cursor but nothing else, laptop screen did not turn on. In the second log, before I switched to Wayland from X11, I forced Kscreen to make the laptop screen primary and DisplayPort secondary. - Started Plasma Wayland session, Laptop screen and DisplayPort didn't turn on, VT switched. Laptop screen turned on, DisplayPort screen failed... Still no go with latest test branch. Attached are both logs. Created attachment 137442 [details]
Wayland Errors Log - New user - with work/zamundaaa/dumb-import branch for kwin
Wayland Errors Log - New user - with work/zamundaaa/dumb-import branch for kwin
Created attachment 137443 [details]
Wayland Errors Log - Existing user - Laptop screen made primary - with work/zamundaaa/dumb-import branch for kwin
Wayland Errors Log - Existing user - Laptop screen made primary - with work/zamundaaa/dumb-import branch for kwin
The laptop display not turning on is unexpected... Maybe I can still find a solution that can be implemented somwhat quickly but it looks like it's gonna take a while I hate to bring this up but: https://gitlab.com/kwinft/kwinft/-/issues/137 Why exactly are we not using wlroots? It's not exactly 'fun' to have to implement your own drm plugin for kwin, deal with all the complexities of display management .... like Xorg DDX did for us behind the scenes.. (In reply to Shawn Starr from comment #64) > I hate to bring this up but: https://gitlab.com/kwinft/kwinft/-/issues/137 > > Why exactly are we not using wlroots? It's not exactly 'fun' to have to > implement your own drm plugin for kwin, deal with all the complexities of > display management .... like Xorg DDX did for us behind the scenes.. Among other things, wlroots will *never* support NVIDIA. That's not confirmed... and wlroots devs dispute this im told on IRC so... (In reply to Shawn Starr from comment #66) > That's not confirmed... and wlroots devs dispute this im told on IRC so... * https://github.com/swaywm/sway/wiki#nvidia-users * https://drewdevault.com/2017/10/26/Fuck-you-nvidia.html The wlroots/sway devs are very public about not supporting NVIDIA. You should sort that out with them. Upon installing Sway for Fedora, starting Sway from SDDM, both displays turned on immediately. So... Sway supports Nvidia, but without support https://github.com/swaywm/sway/blob/master/sway/main.c#L103 Coming back to the KDE side of things.. right now nothing works for me. I can wait and will have to wait. I would prefer we have a common EDID/display detection framework not one for every DE though... Created attachment 137697 [details]
New log from latest code changes
New log from latest code changes
Created attachment 137698 [details]
Coredump from Kwin
Coredump from the session tested,segfaulted
Interesting results with kwin branches: work/zamundaaa/dumb-import + work/primary-gpu-context merged together with latest kwayland-server master + protocols. I *DO* get the DisplayPort turning on, although only *one* screen is able to turn on now.. Log attached Created attachment 137761 [details]
Wayland Error logs - with dumb-import + primary-gpu-context branches
Wayland Error logs - with dumb-import + primary-gpu-context branches
Created attachment 137781 [details]
New log from latest testing - dumb-import + primary-gpu-context + fix-hotplug
New log from latest testing - dumb-import + primary-gpu-context + fix-hotplug
Created attachment 137782 [details]
dumb-import + primary-gpu-context + fix-hotplug w/o SDDM/Xorg VT
dumb-import + primary-gpu-context + fix-hotplug w/o SDDM/Xorg VT
Created attachment 137797 [details]
dumb-import + primary-gpu-context log
dumb-import + primary-gpu-context log
Created attachment 137810 [details]
dumb-import branch only
dumb-import branch only
Created attachment 137838 [details]
dumb-import branch only - latest test
dumb-import branch only - latest test
Created attachment 137848 [details]
dumb-import - April 23rd - log
dumb-import - April 23rd - log
Created attachment 137851 [details]
dumb-import - April 23rd - log - Latest
dumb-import - April 23rd - log - Latest
With latest changes to dumb-import both displays turn on now! Attached outputs Created attachment 138131 [details]
Kwin + latest KWayland server + protocols - both displays turn on
Kwin + latest KWayland server + protocols - both displays turn on
Git commit 7de0f1f2ad022241fb5644ab6798b60b5a94d90f by Xaver Hugl. Committed on 18/05/2021 at 12:54. Pushed by zamundaaa into branch 'master'. platforms/drm: CPU copy for multi-gpu Not all GPUs can scan out linear buffers, so if import with a dmabuf fails manually copy the data into a non-linear gbm buffer instead. M +1 -0 src/plugins/platforms/drm/CMakeLists.txt M +13 -2 src/plugins/platforms/drm/abstract_egl_drm_backend.h M +3 -1 src/plugins/platforms/drm/drm_buffer.h M +26 -2 src/plugins/platforms/drm/drm_buffer_gbm.cpp M +12 -0 src/plugins/platforms/drm/drm_buffer_gbm.h A +54 -0 src/plugins/platforms/drm/dumb_swapchain.cpp [License: GPL(v2.0+)] A +45 -0 src/plugins/platforms/drm/dumb_swapchain.h [License: GPL(v2.0+)] M +165 -81 src/plugins/platforms/drm/egl_gbm_backend.cpp M +13 -3 src/plugins/platforms/drm/egl_gbm_backend.h M +2 -8 src/plugins/platforms/drm/egl_multi_backend.cpp M +7 -23 src/plugins/platforms/drm/scene_qpainter_drm_backend.cpp M +3 -2 src/plugins/platforms/drm/scene_qpainter_drm_backend.h https://invent.kde.org/plasma/kwin/commit/7de0f1f2ad022241fb5644ab6798b60b5a94d90f Git commit 592d2aac05946a8c329e1e8c3d49368160f6af2c by Xaver Hugl. Committed on 31/05/2021 at 07:53. Pushed by zamundaaa into branch 'Plasma/5.22'. platforms/drm: CPU copy for multi-gpu Not all GPUs can scan out linear buffers, so if import with a dmabuf fails manually copy the data into a non-linear gbm buffer instead. (cherry picked from commit 7de0f1f2ad022241fb5644ab6798b60b5a94d90f) M +1 -0 src/plugins/platforms/drm/CMakeLists.txt M +13 -2 src/plugins/platforms/drm/abstract_egl_drm_backend.h M +3 -1 src/plugins/platforms/drm/drm_buffer.h M +26 -2 src/plugins/platforms/drm/drm_buffer_gbm.cpp M +12 -0 src/plugins/platforms/drm/drm_buffer_gbm.h A +54 -0 src/plugins/platforms/drm/dumb_swapchain.cpp [License: GPL(v2.0+)] A +45 -0 src/plugins/platforms/drm/dumb_swapchain.h [License: GPL(v2.0+)] M +165 -81 src/plugins/platforms/drm/egl_gbm_backend.cpp M +13 -3 src/plugins/platforms/drm/egl_gbm_backend.h M +2 -8 src/plugins/platforms/drm/egl_multi_backend.cpp M +7 -23 src/plugins/platforms/drm/scene_qpainter_drm_backend.cpp M +3 -2 src/plugins/platforms/drm/scene_qpainter_drm_backend.h https://invent.kde.org/plasma/kwin/commit/592d2aac05946a8c329e1e8c3d49368160f6af2c |