xorg-server 1.18 and Nvidia 358.16 on GeForce GTX 970M not detecting display sizes correctly

On Arch Linux, there was an upgrade recently to the newest nvidia (358.16) and xorg-server (1.18).

My setup is using the README’s section on using xrandr to use the nvidia card instead of the intel card for rendering (not using things like bumblebee).


Section "Module"
    Load "modesetting"

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:1:0:0"
    Option "AllowEmptyInitialConfiguration"

And for X initialization (startx, sddm, lightdm. All have the same problem)

xrandr --setprovideroutputsource modesetting NVIDIA-0
xrandr --auto

After this update, some very strange behaviour with programs can be observed.
GTK3 programs act as if they are getting a width and height of 0 for the screen. They will never make a window that is 0 pixels in height and width, but things like the context menu (right click) open not where you click, but in the upper left corner of the screen with only one row of text showing with a scroll bar (instead of just showing the menu like normal).
Another example, the nvidia-settings program in GTK3 mode shows in the Layout section where the image of the monitor usually is,
‘hidden because screen height is less than 600 pixels’.
Executing in GTK2 mode with -i will have no display issues.

Wine programs also just simply don’t start for some reason. Or rather, no window is ever displayed with no errors (not even winecfg).

Steam games as well such as CS: GO (well, anything basically) run in extremely low resolutions.
As a note, the X server itself is running in the correct resolutions and the modesetting ‘seems’ to be working correctly as far as I can tell.

If I disable the nvidia driver and only use the intel driver and use the newest X everything works as expected which leads me to believe this is a Nvidia bug.

If you need more information I can give it. Just ask.

nvidia-bug-report.log.gz can be downloaded here https://drive.google.com/file/d/0B4gx2gr9tFoLMmFTRVlzeEFFbW8/view?usp=sharing.


I have the same issue.
Some kind of workaround is adding

Option         "nvidiaXineramaInfo" "False"


Option         "nvidiaXineramaInfoOverride" "1920x1080+0+0"

to the Device section of xorg.conf file.
But it doesn’t fix firefox or nvidia-settings bugs.
nvidia-bug-report.log.gz (82.4 KB)

Link to related Arch bugtracker thread: https://bugs.archlinux.org/task/47151