* Re: [systemd-devel] DisplayPort display non-persistent device naming [not found] <d23c3db1-1ae9-3f23-23a9-4d5d912c5108@gmail.com> @ 2020-10-30 8:09 ` Pekka Paalanen 2020-10-30 8:52 ` Simon Ser 0 siblings, 1 reply; 2+ messages in thread From: Pekka Paalanen @ 2020-10-30 8:09 UTC (permalink / raw) To: Marcin Kocur; +Cc: systemd-devel, dri-devel [-- Attachment #1.1: Type: text/plain, Size: 2120 bytes --] On Thu, 29 Oct 2020 21:53:34 +0100 Marcin Kocur <marcin2006@gmail.com> wrote: > Hello, > > this is the output of turning off and on my display (using power button): ... > The monitor was visible in xrandr as DP-2, after power off and on it's > visible as DP-3 (DP-2 is still there "disconnected"). > > It's troublesome for: > > - GUI display configurators > > - scripting > > - for Xorg configuration which stops to work: > > Section "Monitor" > Identifier "DP-2" > Option "Primary" "true" > EndSection > > Is this a bug or a feature? Hi, this is how the kernel DRM sub-system works. The connector names are not persistent in general, just like you can't expect that the same gfx card appears always at the same /dev/dri/cardN node if you have several. By default, cardN nodes are assigned in the order of which driver instance happens to initialize first and it can be random. Usually hard-wired (in hardware) connectors just happen to always be discovered in the same order, and if you only have a single gfx card in your machine, the connector naming is practically persistent. This is an accident. It is not guaranteed if you have multiple cards or you have MST connectors. MST connectors can appear and disappear dynamically. There is a KMS property that attempts to reflect something about the MST topology so that you might have some hope to match a "connector", but this is not in the connector name. The concept of a persistent connector is problematic if the connector is in a MST monitor for daisy-chaining more monitors - you can always unplug the first monitor making the connector disappear (not just become disconnected). If you want reliable monitor matching, monitor serial number (if present) would be a more reliable method. I'm not sure Xorg config has matching rules for that though, but I suppose RandR based configuration utilities could do it. If you want to discuss this further, dri-devel mailing list is the place - Cc'd. Nothing to do with systemd here, nor even with udev. Thanks, pq [-- Attachment #1.2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 833 bytes --] [-- Attachment #2: Type: text/plain, Size: 160 bytes --] _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [systemd-devel] DisplayPort display non-persistent device naming 2020-10-30 8:09 ` [systemd-devel] DisplayPort display non-persistent device naming Pekka Paalanen @ 2020-10-30 8:52 ` Simon Ser 0 siblings, 0 replies; 2+ messages in thread From: Simon Ser @ 2020-10-30 8:52 UTC (permalink / raw) To: Pekka Paalanen Cc: Marcin Kocur, systemd-devel@lists.freedesktop.org, dri-devel@lists.freedesktop.org On Friday, October 30, 2020 9:09 AM, Pekka Paalanen <ppaalanen@gmail.com> wrote: > On Thu, 29 Oct 2020 21:53:34 +0100 > Marcin Kocur marcin2006@gmail.com wrote: > > > Hello, > > this is the output of turning off and on my display (using power button): > > ... > > > The monitor was visible in xrandr as DP-2, after power off and on it's > > visible as DP-3 (DP-2 is still there "disconnected"). > > It's troublesome for: > > > > - GUI display configurators > > > > - scripting > > > > - for Xorg configuration which stops to work: > > > > > > Section "Monitor" > > Identifier "DP-2" > > Option "Primary" "true" > > EndSection > > Is this a bug or a feature? > > Hi, > > this is how the kernel DRM sub-system works. The connector names are > not persistent in general, just like you can't expect that the same gfx > card appears always at the same /dev/dri/cardN node if you have > several. By default, cardN nodes are assigned in the order of which > driver instance happens to initialize first and it can be random. > > Usually hard-wired (in hardware) connectors just happen to always be > discovered in the same order, and if you only have a single gfx card in > your machine, the connector naming is practically persistent. This is > an accident. It is not guaranteed if you have multiple cards or you > have MST connectors. > > MST connectors can appear and disappear dynamically. There is a KMS > property that attempts to reflect something about the MST topology so > that you might have some hope to match a "connector", but this is not > in the connector name. The concept of a persistent connector is > problematic if the connector is in a MST monitor for daisy-chaining > more monitors - you can always unplug the first monitor making the > connector disappear (not just become disconnected). > > If you want reliable monitor matching, monitor serial number (if > present) would be a more reliable method. I'm not sure Xorg config has > matching rules for that though, but I suppose RandR based configuration > utilities could do it. > > If you want to discuss this further, dri-devel mailing list is the > place - Cc'd. Nothing to do with systemd here, nor even with udev. If you really want to reliably match the physical connector, this proposal from Ville may help: https://lists.freedesktop.org/archives/dri-devel/2019-June/221902.html In fact, MST connectors already all have a PATH prop. What we're missing is a PATH prop for other connectors as well. _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-10-30 8:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <d23c3db1-1ae9-3f23-23a9-4d5d912c5108@gmail.com>
2020-10-30 8:09 ` [systemd-devel] DisplayPort display non-persistent device naming Pekka Paalanen
2020-10-30 8:52 ` Simon Ser
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.