GNOME Bugzilla – Bug 770338
monitor-manager-kms: Use the output naming logic used by the X server
Last modified: 2016-08-29 14:09:48 UTC
See patches
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.
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.
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?
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.
(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.
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