Monitor does not wake up after suspend

After systemctl suspend, one of my monitors often does not wake up properly, but says “no signal”. When I disconnect and connect it again, it works again. I guess it’s because the EDID/DDC-communication fails.

This worked several weeks ago, so it may be caused by some NixOS-software-update or some minor hardware defect. Is this a (known) bug/regression, and is there a workaround?

Details:

  • 2-monitor-setup, 1 connected via DisplayPort, 1 via DisplayPort-DVI-Adapter

  • the DVI-monitor always wakes up correctly, the DisplayPort-monitor only sometimes

  • when the DisplayPort-monitor does not wake up correctly, the chosen mode (1680x1050) is missing in xrandr, and an additional VIRTUAL1 appears:

    DP1 connected primary 1680x1050+1280+0 (normal left inverted right x axis y axis) 480mm x 300mm
    1600x900 60.00

    VIRTUAL1 disconnected (normal left inverted right x axis y axis)
    1680x1050 (0x4a) 146.250MHz -HSync +VSync

  • when it works correctly, the 1680x1050-mode is there, and there is no VIRTUAL1:

    DP1 connected primary 1600x900+1280+0 (normal left inverted right x axis y axis) 480mm x 300mm
    1680x1050 59.95 +
    1600x900 60.00*

    VIRTUAL1 disconnected (normal left inverted right x axis y axis)

I have similar issues with hibernate, but not with suspend.

Xfce desktop on Lenovo Thinkpad X230.

I now do have some workarounds:

  • reconnect the monitor; sometimes the monitor then turns on
  • playing with xrandr, e.g. change the resolution or the layout; I have not tested in detail, what’s necessary)
  • if all that does not work: logout; then lightdm starts and the monitor turns on again