After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 770338 - monitor-manager-kms: Use the output naming logic used by the X server
monitor-manager-kms: Use the output naming logic used by the X server
Status: RESOLVED FIXED
Product: mutter
Classification: Core
Component: wayland
unspecified
Other All
: Normal normal
: ---
Assigned To: mutter-maint
mutter-maint
Depends on:
Blocks:
 
 
Reported: 2016-08-24 14:50 UTC by Rui Matos
Modified: 2016-08-29 14:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
monitor-manager-kms: Use the same connector type names as the X server (1.36 KB, patch)
2016-08-24 14:50 UTC, Rui Matos
committed Details | Review
monitor-manager-kms: Use the output naming logic used by the X server (1.77 KB, patch)
2016-08-24 14:50 UTC, Rui Matos
committed Details | Review

Description Rui Matos 2016-08-24 14:50:05 UTC
See patches
Comment 1 Rui Matos 2016-08-24 14:50:10 UTC
Created attachment 334084 [details] [review]
monitor-manager-kms: Use the same connector type names as the X server

Switch to the connector type names used by the X server's modesetting
driver which, in particular, fixes DVI-A being labeled DVID.
Comment 2 Rui Matos 2016-08-24 14:50:15 UTC
Created attachment 334085 [details] [review]
monitor-manager-kms: Use the output naming logic used by the X server

Switch to the output naming logic used by the X server's modesetting
driver which, in particular, uses drmModeConnector's connector_type_id
instead of connector_id.

The kernel generates new connector_id's every time there are changes
which means we can't identify the same monitor on the same connector
after an hardware hotplug. Switching to connector_type_id fixes this.
Comment 3 Jonas Ådahl 2016-08-25 05:26:02 UTC
Review of attachment 334084 [details] [review]:

Makes sense to me. Are these names used anywhere except in compute_scale() for (probably?) exposing some name to the user?
Comment 4 Jonas Ådahl 2016-08-25 05:35:36 UTC
Review of attachment 334085 [details] [review]:

Does this mean that the different monitors to the same output via the same connector, the become the same? Looking some at the kernel source I can't see how it does anything make it the same only if the same monitor is connected.

Either way, if this is what the X server does, I guess it makes sense to do the same.
Comment 5 Rui Matos 2016-08-25 14:26:30 UTC
(In reply to Jonas Ådahl from comment #3)
> Makes sense to me. Are these names used anywhere except in compute_scale()
> for (probably?) exposing some name to the user?

They're used in ~/.config/monitors.xml but that's not really user visible.

(In reply to Jonas Ådahl from comment #4)
> Does this mean that the different monitors to the same output via the same
> connector, the become the same?

By "we can't identify" I mean the code in meta-monitor-config.c, see the MetaOutputKey usage there. The connector's name is part of this key so if it changes between hotplugs or boots, we can't identify a previously saved configuration.
Comment 6 Rui Matos 2016-08-29 14:09:39 UTC
Attachment 334084 [details] pushed as 7ba8039 - monitor-manager-kms: Use the same connector type names as the X server
Attachment 334085 [details] pushed as c8f2472 - monitor-manager-kms: Use the output naming logic used by the X server