Bug 2088959 - An X11 application accessing the discrete graphics card in a KDE Wayland session causes XWayland to crash
Summary: An X11 application accessing the discrete graphics card in a KDE Wayland sess...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: xorg-x11-server-Xwayland
Version: 36
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Olivier Fourdan
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-05-22 00:06 UTC by Alastor Tenebris
Modified: 2022-05-27 01:09 UTC (History)
6 users (show)

Fixed In Version: xorg-x11-server-Xwayland-22.1.2-1.fc36
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-05-27 01:09:55 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
backtrace (22.23 KB, text/plain)
2022-05-24 07:37 UTC, Alastor Tenebris
no flags Details


Links
System ID Private Priority Status Summary Last Updated
freedesktop.org Gitlab xorg xserver issues 1344 0 None opened Xwayland crashes every time one tries to start any Xwayland app in KDE Plasma Wayland 2022-05-24 07:44:48 UTC

Description Alastor Tenebris 2022-05-22 00:06:11 UTC
Description of problem:
When a Chrome based app that uses X11 is run, many times the app will crash and take xwayland with it, preventing apps that need xwayland to run.

Version-Release number of selected component (if applicable):
Fedora 36 KDE

How reproducible:
Varies. The chromium package, Flatpak Chrome, Flatpak MS Edge, and nwjs seem to always cause a crash.

Steps to Reproduce:
1. Run an application that uses Chromium


Actual results:
The app and xwayland crashes. Apps that need xwayland no longer work. Appindicators that were from xwayland apps crash. 

Expected results:
The apps run

Additional info:
nwjs always crashes, even on GNOME, though it doesn't take out xwayland with it.

nwjs crashes with the following error:
"libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null)"

This is a laptop with switchable Vega 8/Polaris graphics.


This did not happen on Fedora 35.

Comment 1 Alastor Tenebris 2022-05-23 22:12:19 UTC
As it turns out this actually has nothing to do with Chromium. Filing a separate one for the actual issue.

Comment 2 Alastor Tenebris 2022-05-23 22:15:14 UTC
Ignore that.

To reproduce this issue, run DRI_PRIME=1 glxinfo under a wayland session in KDE, and XWayland immediately crashes.

Comment 3 Olivier Fourdan 2022-05-24 06:19:45 UTC
Well, actually, this has nothing to do with "Wayland" (the component) which is just a set of protocol definitions and a small IPC library,

That said, if Xwayland crashes, the first thing to provide is a backtrace (with symbols) of Xwayland in gdb.

Can you please provide the following:

1. Install the debuginfo package for xorg-x11-server-Xwayland
2. Run "coredumpctl gdb" on the Xwayland process that crashed
3. attach the output of "bt" and "bt full" from the gdb session

Comment 4 Alastor Tenebris 2022-05-24 07:37:16 UTC
Created attachment 1882567 [details]
backtrace

I've never generated a backtrace before, so hopefully I did this right.

Comment 5 Olivier Fourdan 2022-05-24 07:44:48 UTC
(In reply to Alastor Tenebris from comment #4)
> I've never generated a backtrace before, so hopefully I did this right.

You did, perfect thanks!

That is probably a dupe of bug 2088807

Was it you who filed https://gitlab.freedesktop.org/xorg/xserver/-/issues/1344 upstream as well?

Comment 6 Alastor Tenebris 2022-05-24 07:48:21 UTC
(In reply to Olivier Fourdan from comment #5)
> (In reply to Alastor Tenebris from comment #4)
> > I've never generated a backtrace before, so hopefully I did this right.
> 
> You did, perfect thanks!
> 
> That is probably a dupe of bug 2088807
> 
> Was it you who filed
> https://gitlab.freedesktop.org/xorg/xserver/-/issues/1344 upstream as well?

That was not me. 

Here's the upstream bug report: https://bugs.kde.org/show_bug.cgi?id=452062. Looks like it has something to do with having switchable AMD GPUs.

Comment 7 Olivier Fourdan 2022-05-24 07:53:52 UTC
I fired a scratch build for Xwayland with the fix from https://gitlab.freedesktop.org/xorg/xserver/-/issues/1344, can you please give this build a try once it's complete:

  https://koji.fedoraproject.org/koji/taskinfo?taskID=87434411

Comment 8 Alastor Tenebris 2022-05-24 08:04:06 UTC
Yep that seemed to fix it.

Comment 9 Olivier Fourdan 2022-05-24 08:14:29 UTC
Brilliant, thanks for testing and confirming!

Comment 10 Fedora Update System 2022-05-25 11:56:57 UTC
FEDORA-2022-0ee78d34e9 has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2022-0ee78d34e9

Comment 11 Fedora Update System 2022-05-26 02:32:14 UTC
FEDORA-2022-0ee78d34e9 has been pushed to the Fedora 36 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2022-0ee78d34e9`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-0ee78d34e9

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 12 Fedora Update System 2022-05-27 01:09:55 UTC
FEDORA-2022-0ee78d34e9 has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.