how can I identify which video card on a mutli-card linux box a display belongs to
chris at chris-wilson.co.uk
Mon Nov 10 00:56:24 PST 2014
On Mon, Nov 10, 2014 at 04:31:59PM +0800, Zhang Fan wrote:
> Hi all,
> I'm developing a video matrix system for Linux. Typically multiple
> vendors' video card and/or multiple cards of same vendor/model might
> be used in one system.
> I can list the display by using 'xrandr' program and read the
> display card information from /sys/class/drm/ directory. But I can't
> figure out how to relate these two kinds information. i.e, which
> card/port does a display belongs to?
> 'xrandr --verbose' command lists the 'Identifier' of each display
> but it seems volatile and might change after reboot and has nothing
> to do with the information in /sys/class/drm.
If your devices support DRI2/DRI3, you can send a DRI request to query
the device node for a screen. Might be a nice extension to xrandr
--verbose, or perhaps a new driinfo.
Chris Wilson, Intel Open Source Technology Centre
More information about the xorg