Add support for "boot_display" attribute

Bug #2136140 reported by Aaron Erhardt
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Drivers Common
New
Undecided
Unassigned
gdm3 (Ubuntu)
Fix Committed
Undecided
Unassigned
libpciaccess (Ubuntu)
Triaged
Undecided
Unassigned
mesa (Ubuntu)
Triaged
Low
Unassigned
mutter (Ubuntu)
Triaged
Medium
Alessandro Astone
nvidia-prime (Ubuntu)
New
Undecided
Unassigned
xorg-server (Ubuntu)
Triaged
Undecided
Unassigned

Bug Description

Since Kernel 6.18, there is a new "boot_display" attribute for display drivers that do not represent VGA compatible devices: https://<email address hidden>/T/#t

This attribute essentially replaces the "boot_vga" attribute that was used by user space applications to determine which is the primary GPU on a system. This is no longer accurate, e. g. for devices with recent AMD iGPUs, because they don't appear as VGA compatible devices.

Unfortunately, sticking to the old attribute can lead to an incorrect choice of primary GPU, resulting in user space being unable to render. However, current versions of the xserver still don't honor the new "boot_display" attribute, making some devices unusable with X unless you modify the config to select another primary GPU.

There are already patches for Xorg, but they haven't been merged and honestly, the entire X-project appears quite dead.
Therefore, it would be great to merge the patches at least into the Ubuntu packages:

- https://gitlab.freedesktop.org/xorg/lib/libpciaccess/-/merge_requests/39
- https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/2038

Revision history for this message
Alessandro Astone (aleasto) wrote :

I suppose mutter should also consider this new attribute?

Revision history for this message
Aaron Erhardt (tuxedo-aer) wrote :

As far as I know, most Wayland servers have a different way to detect the primary display, so mutter is not directly affected, but only when you use the Xorg backend. At least so far, using Wayland solved the problem (under KDE at least). I can help with testing if you want because I have access to an affected device.

Revision history for this message
Alessandro Astone (aleasto) wrote (last edit ):

One of the heuristics mutter uses is boot_vga: https://gitlab.gnome.org/GNOME/mutter/-/blob/3a41f04f19c1fcd4d4c93ff49b87b7515a9b5f54/src/backends/native/meta-renderer-native.c#L2426

But there are other higher-priority heuristics, like whether the GPU has a built-in panel connected.

Changed in mesa (Ubuntu):
importance: Undecided → Low
status: New → Triaged
Changed in mutter (Ubuntu):
status: New → Triaged
Changed in xorg (Ubuntu):
status: New → Triaged
Revision history for this message
Alessandro Astone (aleasto) wrote :

Mesa also uses boot_vga for vulkan device selection, but only when not running in Wayland or Xorg

Changed in mutter (Ubuntu):
importance: Undecided → Medium
assignee: nobody → Alessandro Astone (aleasto)
milestone: none → ubuntu-26.04
Revision history for this message
Aaron Erhardt (tuxedo-aer) wrote :

For mutter at least, boot_vga only seems to be a fallback in the native renderer. I think this code specially prevents the problem from appearing because it has a higher precedence than the boot_vga check: https://gitlab.gnome.org/GNOME/mutter/-/blob/3a41f04f19c1fcd4d4c93ff49b87b7515a9b5f54/src/backends/native/meta-renderer-native.c#L2454-2468

Regardless, the boot_vga code in mutter should now also consider the new boot_display attribute, but I'm not sure whether this is relevant in reality.

affects: xorg (Ubuntu) → xorg-server (Ubuntu)
Changed in libpciaccess (Ubuntu):
status: New → Triaged
Revision history for this message
Alessandro Astone (aleasto) wrote :
Changed in gdm3 (Ubuntu):
status: New → Fix Committed
milestone: none → ubuntu-26.04
tags: added: fixed-in-gdm3-50.alpha fixed-upstream resolute
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.