Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 873154 - gnome-base/gdm-43.0 61-gdm.rules wrongly assumes location of systemd's system-sleep dir and disables wayland on nvidia due to not finding a file
Summary: gnome-base/gdm-43.0 61-gdm.rules wrongly assumes location of systemd's system...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-09-27 08:57 UTC by Thomas Scheiblauer
Modified: 2022-12-06 09:13 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
changes gdm's udev rules to match systemd's path on gentoo (nvidia-sleep-systemd-path.patch,893 bytes, patch)
2022-10-02 20:05 UTC, Alexandra Parker
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Scheiblauer 2022-09-27 08:57:41 UTC
The line
TEST{0711}!="/usr/lib/systemd/system-sleep/nvidia", GOTO="gdm_disable_wayland"
inside the file
/lib/udev/rules.d/61-gdm.rules
from the package
gnome-base/gdm-43.0
disables Wayland on Nvidia cards because it tests for the wrong path.

The actual path where x11-drivers/nvidia-drivers-515.65.01 installs this files is "/lib/systemd/system-sleep/nvidia" so the line should read
TEST{0711}!="/lib/systemd/system-sleep/nvidia", GOTO="gdm_disable_wayland"

After correcting this, Wayland is available on Nvidia cards using the proprietary driver and works currently fantastically.

Reproducible: Always

Steps to Reproduce:
1. Boot with an Nvidia GPU installed using the proprietary Nvidia driver
2. If you use the Gnome desktop there should be choices for Gnome and Gnome on Xorg where Gnome would open a wayland session.
3. Login and determine the session type by using "loginctl show-session <SESSION-ID>"
Actual Results:  
Desktop sessions can only be started on X11

Expected Results:  
e.g. Gnome and Gnome on Xorg session choices in GDM (or the respective KDE pendants).
"loginctl show-session <SESSION-ID>" should display
...
Type=wayland
...
Comment 1 Ionen Wolkens gentoo-dev 2022-09-27 09:10:38 UTC
Think this should be fixed from nvidia's end to install in /usr/lib given systemd is moving toward merged-usr (aka doesn't use /lib). I'll have a look soon.

That aside, testing for that file to enable/disable wayland is a bit odd. It has no relation to wayland and installing this could even be optional (cc gdm for awareness)
Comment 2 Ionen Wolkens gentoo-dev 2022-09-27 09:17:49 UTC
(In reply to Ionen Wolkens from comment #1)
 > That aside, testing for that file to enable/disable wayland is a bit odd. It
> has no relation to wayland and installing this could even be optional (cc
> gdm for awareness)

On a side-note, this is new in gdm-43, 42 didn't do this.
Comment 3 Ionen Wolkens gentoo-dev 2022-09-27 09:45:44 UTC
Hrm, upon closer look I don't think I should move this file at the moment given it's correct.

    $ pkg-config systemd --variable=systemd_sleep_dir
    /lib/systemd/system-sleep

I could probably make it use pkg-config to futureproof the right location, but it doesn't help anything with gdm unless it's a merged-usr system.

I think this need to be fixed in gdm after all. As I mentioned, checking for this file doesn't really make sense in the first place.
Comment 4 Alexandra Parker 2022-10-02 20:05:42 UTC
Created attachment 815953 [details, diff]
changes gdm's udev rules to match systemd's path on gentoo

Like this? Or is that path actually configurable?
Comment 5 Pacho Ramos gentoo-dev 2022-11-20 08:36:56 UTC
Maybe we should sed the location following split-usr USE flag. Like that, the setting will also be updated in the future when split-usr is going to be disabled in the future due to systemd dropping its support in the second half of 2023
Comment 6 Pacho Ramos gentoo-dev 2022-12-04 19:04:12 UTC
(In reply to Pacho Ramos from comment #5)
> Maybe we should sed the location following split-usr USE flag. Like that,
> the setting will also be updated in the future when split-usr is going to be
> disabled in the future due to systemd dropping its support in the second
> half of 2023

And regarding if gdm should or not check for that file... well... that would be more like an upstream issue I think :/, I am also unsure about what they could do as an alternative to ensure the setup is ready to enable wayland
Comment 7 Pacho Ramos gentoo-dev 2022-12-06 09:13:51 UTC
(In reply to Pacho Ramos from comment #5)
> Maybe we should sed the location following split-usr USE flag. Like that,
> the setting will also be updated in the future when split-usr is going to be
> disabled in the future due to systemd dropping its support in the second
> half of 2023

As the /lib -> /usr/lib symlink will be there, we wouldn't be need to rely on the USE flag and simply rely on systemd_get_sleepdir getting updated in the future :)