[Wayland][Nvidia] gdm default use Xorg in 22.04 if proprietary nvidia installed

Bug #1962523 reported by jeremyszu
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OEM Priority Project
Fix Released
Critical
jeremyszu
gdm3 (Ubuntu)
Fix Released
Wishlist
jeremyszu

Bug Description

[Impact]

 * In Ubuntu 22.04, gdm should use Wayland by default even if proprietary nVidia driver is in use.
 * gdm upstream prefers Wayland if nvidia version newer than (or equal) to 510. It same as Ubuntu's strategy[1].

[Test Plan]

Steps:
1. Download jammy daily build
2. Install nvidia driver by selecting "install third-party packages.." during the installation.
3. Login without selecting modes (e.g. "Ubuntu" or "Ubuntu on Wayland" or enable auto-login during the installation.

[Where problems could occur]
 * If nVidia GPU doesn't support Wayland then it will be a problem but it doesn't means this patch leads a regression, instead, the problem should always there as it is if the user switches to Wayland mode no matter default mode.
 * This ticket switches the default mode to Wayland. If there is a problem then user will encounter it after the installation which has bad experience.
 * However, it's not regression because Jammy is a new LTS version and we decide to switch to Wayland. If a problem occurs, then we fix it.

---

[Steps to reproduce]
1. Download jammy daily build
2. Install nvidia driver by selecting "install third-party packages.." during the installation.
3. Login without selecting modes (e.g. "Ubuntu" or "Ubuntu on Wayland" or enable auto-login during the installation.

[Expect result]
gdm using wayland (at least with nvidia-510)

[Actual result]
gdm using xorg

1) The release of Ubuntu you are using, via 'lsb_release -rd' or System -> About Ubuntu

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu Jammy Jellyfish (development branch)
Release: 22.04
Codename: jammy

2) The version of the package you are using, via 'apt-cache policy pkgname' or by checking in Software Center

$ apt policy gdm3
gdm3:
  Installed: 41.3-1ubuntu2
  Candidate: 41.3-1ubuntu2
  Version table:
 *** 41.3-1ubuntu2 500
        500 http://tw.archive.ubuntu.com/ubuntu jammy/main amd64 Packages
        100 /var/lib/dpkg/status

Reference:
[1] Ubuntu Jammy should use Wayland as default with nVidia
https://docs.google.com/document/d/1wK4vGUXaDG2Nd7e3XGI9kDpNzReka_VOHO7sgRqce5s/edit?disco=AAAAVxVMzfA

jeremyszu (os369510)
Changed in oem-priority:
assignee: nobody → jeremyszu (os369510)
importance: Undecided → Critical
status: New → Confirmed
tags: added: oem-priority
jeremyszu (os369510)
description: updated
Changed in gdm3 (Ubuntu):
assignee: nobody → jeremyszu (os369510)
Changed in oem-priority:
status: Confirmed → In Progress
Revision history for this message
jeremyszu (os369510) wrote :

Test on my P350 with nvidia-510 on Jammy daily build with dist-upgrade.

Changed in oem-priority:
status: In Progress → Triaged
jeremyszu (os369510)
description: updated
tags: added: jammy nvidia
Changed in gdm3 (Ubuntu):
status: New → In Progress
jeremyszu (os369510)
summary: - [Wayland][Nvidia] gdm default use Xorg in 22.04
+ [Wayland][Nvidia] gdm default use Xorg in 22.04 if proprietary nvidia
+ installed
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Upstream has made a good case for defaulting to Xorg at least on hybrid systems:

  https://gitlab.gnome.org/GNOME/mutter/-/issues/2166#note_1399945

  https://gitlab.gnome.org/GNOME/gdm/-/merge_requests/171

I'm going to investigate the situation in the coming days/weeks and will report back in bug 1959888.

tags: added: nvidia-wayland
Changed in gdm3 (Ubuntu):
importance: Undecided → Wishlist
Revision history for this message
jeremyszu (os369510) wrote :

@Daniel,

So for lp:#1959888, user confirmed it seems be fixed by nvidia-510. It makes sense on the patch.
The patch from comment#1 is indeed enable Wayland only if nvidia-510.

tags: added: gdm3
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Bug 1959888 is still open, awaiting either feedback from the user or for me to confirm it.

As for this bug, please propose the patch to upstream first:

  https://gitlab.gnome.org/GNOME/gdm/-/merge_requests

We don't want to conflict with their existing plans:

  https://gitlab.gnome.org/GNOME/gdm/-/merge_requests/171

and more generally we don't want to fork codebases without at least trying to merge fixes upstream first.

Revision history for this message
jeremyszu (os369510) wrote :
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Oops, yes, sorry.

tags: added: fixed-in-42 fixed-upstream
jeremyszu (os369510)
tags: added: jiayi
Revision history for this message
jeremyszu (os369510) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gdm3 - 41.3-1ubuntu3

---------------
gdm3 (41.3-1ubuntu3) jammy; urgency=medium

  [ Jeremy Szu ]
  * d/p/ubuntu/gdm.rules-Prefer-Wayland-with-NVIDIA-510.patch
      - default to Wayland for nvidia 510 drivers (LP: #1962523)

 -- Sebastien Bacher <email address hidden> Tue, 15 Mar 2022 13:20:58 +0100

Changed in gdm3 (Ubuntu):
status: In Progress → Fix Released
jeremyszu (os369510)
Changed in oem-priority:
status: Triaged → Fix Released
Revision history for this message
Menno van G (mgrinsven) wrote :

Is it possible a regression has occurred? Right now I do not have the possibility to select Wayland when using the nVidia 5.10 drivers. I only can use X11? I was using Wayland without major problems, but after updating I can only use X11.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Yes, Menno, this is a regression in that Ubuntu 21.10 enabled Wayland for Nvidia and Ubuntu 22.04 now does not.

An issue was identified with suspend not working for GNOME requirements. Once the Nvidia drivers are updated to fix that issue in a future stable release update, Wayland should be available again.

See https://launchpad.net/bugs/1969198 or file a new bug.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.