Skip to contentSkip to conversation

multiple cards and monitors with xrandr and opengl

DISCUSSION Sampsa Riikonen 4 participants 6 messages May 7, 2017 – May 9, 2017 5 messages not in the archive

lore
Share & tools
lore
#0 lore raw

Dear Devs,

We have achieved a desktop of up to six monitors, with openGL running succesfully on the desktop, with the following setup/features:

* Ubuntu 16+
* Xrandr
* Noveau driver
* Two gtx750 graphic cards

Each (identical) graphic card has 2xHDMI + 2xDVI connectors, which we connect to the monitor array.

So far it works with six monitors, but we'd like to achieve eight. However, throwing in more monitors, results in monitors starting to drop out (black screen). However, xrandr sees them correctly.

The nv$dia proprietary driver is not an option - they have artificially restricted the amount of monitors in the "base mosaic" feature (ref.
https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/x-org-drm/46705-linux-multi-head-success-with-8-monitors-in-1-x-screen-without-xinerama
).

What might cause the monitors to drop out? I can provide some logs later next week (which file should I look at?)

Could using nv$dia's proprietary firmware in noveau help?

Regards,

Sampsa

P.S. This seems to be a bit outdated.. ?

https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

.. it implies that xinerama must be used to combine screens from two different graphics cards into a single screen which implies that opengl should not work, right?

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

A message that is not in the archive (sent off-list or not yet received): 47b68f22-acb6-a706-87d7-b494d30be75e-X3B1VOXEql0@public.gmane.org

#2 lore raw
Quoted 31 lines · Sampsa Riikonen

Dear Devs,

We have achieved a desktop of up to six monitors, with openGL running succesfully on the desktop, with the following setup/features:

* Ubuntu 16+
* Xrandr
* Noveau driver
* Two gtx750 graphic cards

Each (identical) graphic card has 2xHDMI + 2xDVI connectors, which we connect to the monitor array.

So far it works with six monitors, but we'd like to achieve eight. However, throwing in more monitors, results in monitors starting to drop out (black screen). However, xrandr sees them correctly.

The nv$dia proprietary driver is not an option - they have artificially restricted the amount of monitors in the "base mosaic" feature (ref.
https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/x-org-drm/46705-linux-multi-head-success-with-8-monitors-in-1-x-screen-without-xinerama
).

What might cause the monitors to drop out? I can provide some logs later next week (which file should I look at?)

Could using nv$dia's proprietary firmware in noveau help?

Regards,

Sampsa

Quoted 7 lines

P.S. This seems to be a bit outdated.. ?

https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

.. it implies that xinerama must be used to combine screens from two different graphics cards into a single screen which implies that opengl should not work, right?

Using reverse prime with a ton of screens has had a questionable success rate. Using Xinerama Just Works (tm). But you do lose direct rendering (but you still get OpenGL via indirect GLX, assuming the X server has that enabled). However in the past, this hasn't been an issue for the people trying to create such arrangements.

With reverse prime, I believe it's all just one big framebuffer, so you run into fb size limits. I think we restrict it to 16k x 16k in size.

Cheers,

-ilia
_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

A message that is not in the archive (sent off-list or not yet received): CAKb7Uvh3mQi7-dr0fCwDF2r2-EMVHN8MNbDaREJxNYT+XpMAKQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org

#4 lore raw
Quoted 46 lines · Ilia Mirkin
Quoted 31 lines · Sampsa Riikonen

Dear Devs,

We have achieved a desktop of up to six monitors, with openGL running succesfully on the desktop, with the following setup/features:

* Ubuntu 16+
* Xrandr
* Noveau driver
* Two gtx750 graphic cards

Each (identical) graphic card has 2xHDMI + 2xDVI connectors, which we connect to the monitor array.

So far it works with six monitors, but we'd like to achieve eight. However, throwing in more monitors, results in monitors starting to drop out (black screen). However, xrandr sees them correctly.

The nv$dia proprietary driver is not an option - they have artificially restricted the amount of monitors in the "base mosaic" feature (ref.
https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/x-org-drm/46705-linux-multi-head-success-with-8-monitors-in-1-x-screen-without-xinerama
).

What might cause the monitors to drop out? I can provide some logs later next week (which file should I look at?)

Could using nv$dia's proprietary firmware in noveau help?

Regards,

Sampsa

Quoted 7 lines

P.S. This seems to be a bit outdated.. ?

https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

.. it implies that xinerama must be used to combine screens from two different graphics cards into a single screen which implies that opengl should not work, right?

Using reverse prime with a ton of screens has had a questionable success rate. Using Xinerama Just Works (tm). But you do lose direct rendering (but you still get OpenGL via indirect GLX, assuming the X server has that enabled). However in the past, this hasn't been an issue for the people trying to create such arrangements.

Quoted 3 lines

With reverse prime, I believe it's all just one big framebuffer, so you run into fb size limits. I think we restrict it to 16k x 16k in size.

Another possibility is running into memory bandwidth limitations.

Quoted 9 lines

Cheers,

-ilia
_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

A message that is not in the archive (sent off-list or not yet received): ec963c6a-0031-fb69-4b83-9d54c14e66c4-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org

#6 lore raw
Quoted 54 lines · Ben Skeggs
Quoted 1 line · Ilia Mirkin

On Sun, May 7, 2017 at 7:17 AM, Sampsa Riikonen

Quoted 3 lines · <[email protected]> wrote:
Quoted 3 lines

Dear Devs,

We have achieved a desktop of up to six monitors, with openGL

running

Quoted 8 lines
Quoted 8 lines

succesfully on the desktop, with the following setup/features:

* Ubuntu 16+
* Xrandr
* Noveau driver
* Two gtx750 graphic cards

Each (identical) graphic card has 2xHDMI + 2xDVI connectors, which

we

Quoted 4 lines
Quoted 4 lines

connect to the monitor array.

So far it works with six monitors, but we'd like to achieve eight. However, throwing in more monitors, results in monitors starting to

drop

Quoted 3 lines
Quoted 3 lines

out (black screen). However, xrandr sees them correctly.

The nv$dia proprietary driver is not an option - they have

artificially

Quoted 2 lines
Quoted 2 lines

restricted the amount of monitors in the "base mosaic" feature (ref.

https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/x-org-drm/46705-linux-multi-head-success-with-8-monitors-in-1-x-screen-without-xinerama

Quoted 9 lines
Quoted 9 lines

).

What might cause the monitors to drop out? I can provide some logs later next week (which file should I look at?)

Could using nv$dia's proprietary firmware in noveau help?

Regards,

Quoted 8 lines
Quoted 8 lines

Sampsa

P.S. This seems to be a bit outdated.. ?

https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

.. it implies that xinerama must be used to combine screens from two different graphics cards into a single screen which implies that

opengl

Quoted 8 lines
Quoted 1 line

should not work, right?

Using reverse prime with a ton of screens has had a questionable success rate. Using Xinerama Just Works (tm). But you do lose direct rendering (but you still get OpenGL via indirect GLX, assuming the X server has that enabled). However in the past, this hasn't been an issue for the people trying to create such arrangements.

Quoted 5 lines
Quoted 3 lines

With reverse prime, I believe it's all just one big framebuffer, so you run into fb size limits. I think we restrict it to 16k x 16k in size.

Another possibility is running into memory bandwidth limitations.

And PCIe bandwidth, especially if only on 2.5 GT/s speed. So if this is done through Reverse Prime, reclocking is a must.

Quoted 9 lines
Quoted 9 lines

Cheers,

-ilia
_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

Quoted 4 lines

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

A message that is not in the archive (sent off-list or not yet received): 593D569B-9954-4335-9395-5507F0059052-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org

#8 lore raw

Hi,

Thanks for your advice..! I have a few follow-up questions (tagged below Q1, Q2 and Q3). Any help highly/extremely appreciated.

Regarding to "reverse prime", etc. I have read the following page:

https://nouveau.freedesktop.org/wiki/Optimus/

So, if we want a single "macro" xscreen that spans two cards, for example:

Card 0, connected to monitor 0
Card 1, connected to monitor 1
=> a single xscreen

the only (possible) way to do this, is ..

* Card 0 composes the "macro" framebuffer
* .. and sends the relevant parts to Card 1

(Q1) Is this interpretation correct?

The command

xrandr --listproviders

gives me

Providers: number : 3
Provider 0: id: 0xd0 cap: 0x9, Source Output, Sink Offload crtcs: 4 outputs: 4 associated providers: 2 name:modesetting Provider 1: id: 0x47 cap: 0x6, Sink Output, Source Offload crtcs: 4 outputs: 4 associated providers: 2 name:modesetting Provider 2: id: 0x47 cap: 0x6, Sink Output, Source Offload crtcs: 4 outputs: 4 associated providers: 2 name:modesetting

I am a bit confused that the name is not "Intel" and/or "nouveau".. and "modesetting" is a kernel module that finds display modes, right?

(Q2) Am I doing something wrong here?

I made a simple test and, indeed, the data transfer (as pointed out by Karol) from card 0 => 1 manifested itself in glxgears:

* Open glxgears in monitor 0. Gears roll about fine.
* .. drag the glxgears to monitor 1. Gears start to be choppy with occasional freezing

However, there is an easy way to avoid this problem, by using the good'old xscreens

Card 0, connected to monitor 0 => xscreen 0 (i.e., DISPLAY=:0.0) Card 1, connected to monitor 1 => xscreen 1 (i.e., DISPLAY=:0.1)

This fixed the issue when using nv$dia's proprietary driver. When I do

DISPLAY=:0.1 glxgears

The gears appear in the second screen (card 1) and roll fine. :)

However, to my great disappointment, it seems that noveau is not supporting separate xscreens any more. There was no way around this .. I am using lightdm display manager and the xcfe4 window manager. With nv$idia prop. drivers I could get two separate xscreens, but never with nouveau. When testing the two cases, I used (almost) identical xorg files (see below).

(Q3) Has the support for separate xscreens been scrapped from the noveau driver?

I was also playing around with the "zaphod heads" option (as per http://blog.timmattison.com/archives/2012/01/16/how-to-set-up-multi-head-x-in-debian-using-nvidia-cards/ ), but with little success

Regards,

Sampsa

The following xorg file was used succesfully for "nvidia" (removing "#" and replacing "noveau" with "nvidia") and not-so-succesfully for noveau. I could get two separate xscreens only for the "nvidia" case.

Section "ServerLayout"

    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    Screen      1  "Screen1" RightOf "Screen0"
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"

EndSection

Section "Files"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
# HorizSync source: edid, VertRefresh source: edid
Identifier "Monitor0"
VendorName "Unknown"
ModelName "BenQ GL2450"
HorizSync 30.0 - 83.0
VertRefresh 50.0 - 76.0
Option "DPMS"
EndSection

Section "Monitor"
# HorizSync source: unknown, VertRefresh source: unknown
Identifier "Monitor1"
VendorName "Unknown"
ModelName "DFP-1"
HorizSync 0.0 - 0.0
VertRefresh 0.0
Option "DPMS"
EndSection

Section "Device"

    Identifier     "Device0"
    Driver         "nouveau"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 750 Ti"
    BusID          "PCI:1:0:0"

EndSection

Section "Device"

    Identifier     "Device1"
    Driver         "nouveau"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GTX 750 Ti"
    BusID          "PCI:2:0:0"

EndSection

Section "Screen"

    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"

DefaultDepth 24
Option "Stereo" "0"
#Option "nvidiaXineramaInfoOrder" "DFP-0"
Option "metamodes" "1920x1080 +0+0"
#Option "SLI" "Off"
#Option "MultiGPU" "Off"
#Option "BaseMosaic" "off"
SubSection "Display"
Depth 24
EndSubSection
EndSection

Section "Screen"

    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "Monitor1"

DefaultDepth 24
Option "Stereo" "0"
Option "metamodes" "1024x768 +0+0"
#Option "SLI" "Off"
#Option "MultiGPU" "Off"
#Option "BaseMosaic" "off"
SubSection "Display"
Depth 24
EndSubSection
EndSection

Quoted 70 lines · Karol Herbst
Quoted 53 lines · Ben Skeggs
Quoted 1 line · Ilia Mirkin

On Sun, May 7, 2017 at 7:17 AM, Sampsa Riikonen

Quoted 3 lines · <[email protected]> wrote:
Quoted 3 lines

Dear Devs,

We have achieved a desktop of up to six monitors, with openGL

running

Quoted 8 lines
Quoted 8 lines

succesfully on the desktop, with the following setup/features:

* Ubuntu 16+
* Xrandr
* Noveau driver
* Two gtx750 graphic cards

Each (identical) graphic card has 2xHDMI + 2xDVI connectors, which

we

Quoted 4 lines
Quoted 4 lines

connect to the monitor array.

So far it works with six monitors, but we'd like to achieve eight. However, throwing in more monitors, results in monitors starting to

drop

Quoted 3 lines
Quoted 3 lines

out (black screen). However, xrandr sees them correctly.

The nv$dia proprietary driver is not an option - they have

artificially

Quoted 2 lines
Quoted 2 lines

restricted the amount of monitors in the "base mosaic" feature (ref.

https://www.phoronix.com/forums/forum/linux-graphics-x-org-drivers/x-org-drm/46705-linux-multi-head-success-with-8-monitors-in-1-x-screen-without-xinerama

Quoted 9 lines
Quoted 9 lines

).

What might cause the monitors to drop out? I can provide some logs later next week (which file should I look at?)

Could using nv$dia's proprietary firmware in noveau help?

Regards,

Quoted 8 lines
Quoted 8 lines

Sampsa

P.S. This seems to be a bit outdated.. ?

https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

.. it implies that xinerama must be used to combine screens from two different graphics cards into a single screen which implies that

opengl

Quoted 7 lines
Quoted 1 line

should not work, right?

Using reverse prime with a ton of screens has had a questionable success rate. Using Xinerama Just Works (tm). But you do lose direct rendering (but you still get OpenGL via indirect GLX, assuming the X server has that enabled). However in the past, this hasn't been an issue for the people trying to create such arrangements.

Quoted 5 lines
Quoted 3 lines

With reverse prime, I believe it's all just one big framebuffer, so you run into fb size limits. I think we restrict it to 16k x 16k in size.

Another possibility is running into memory bandwidth limitations.

And PCIe bandwidth, especially if only on 2.5 GT/s speed. So if this is done through Reverse Prime, reclocking is a must.

Quoted 8 lines
Quoted 8 lines

Cheers,

-ilia
_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

Quoted 8 lines
Quoted 4 lines

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau

A message that is not in the archive (sent off-list or not yet received): 21c5d74f-e4cd-9fad-f7f4-2677f6b6602e-X3B1VOXEql0@public.gmane.org

#10 lore raw
Quoted 4 lines · Sampsa Riikonen

I am a bit confused that the name is not "Intel" and/or "nouveau".. and "modesetting" is a kernel module that finds display modes, right?

(Q2) Am I doing something wrong here?

No. You are using a distribution which has chosen to stop supporting the device-specific drivers and instead use the "generic" modesetting ddx, which uses the underlying GL library for acceleration.

I would not recommend doing this, but as with so many things in the world, nobody really cares about that.

Quoted 6 lines

(Q3) Has the support for separate xscreens been scrapped from the noveau driver?

I was also playing around with the "zaphod heads" option (as per
http://blog.timmattison.com/archives/2012/01/16/how-to-set-up-multi-head-x-in-debian-using-nvidia-cards/
), but with little success

Use this guide to put separate monitors on separate X screens:
https://nouveau.freedesktop.org/wiki/MultiMonitorDesktop/

Just leave out the Xinerama enable bit.

Cheers,

-ilia
_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau