Skip to content

Multi-monitor layout reset to defaults after amdgpu runtime resume ("Output has no active mode" → "Broken config, all outputs disabled") #2886

Description

@vladngogo

Summary

On an AMD RDNA3 desktop with two DisplayPort monitors, cosmic-comp fails to
re-apply the saved output configuration whenever the dGPU has runtime-suspended
(BACO) and the screens are woken. Its recovery path then disables all outputs
and resets them to defaults
:

  • rotation, scale and position are lost;
  • one monitor often stays dark until the layout is re-applied from
    Settings → Displays.

It happened on 4 of 4 screen wakes that followed a GPU runtime suspend, and
0 of 8 once GPU runtime PM was disabled. There is a workaround (below), but
the all-or-nothing recovery seems worth fixing regardless.

Environment

  • Pop!_OS 26.04, COSMIC (Wayland)
  • cosmic-comp 0.1~1789989464~26.04~cd881a4
  • Kernel 7.1.5-76070105-generic, Mesa 26.1.6, libdrm 2.4.134
  • GPU: AMD Radeon RX 7700 XT / 7800 XT (Navi 32, amdgpu; runtime PM via BACO)
  • Kernel cmdline extras: amdgpu.dcdebugmask=0x20002 amdgpu.sg_display=0 (for an
    unrelated suspend issue)
  • Displays:
    • DP-1: LG HDR WQHD, 3440×1440@59.973, normal, 100%, Xwayland primary
    • DP-2: LG HDR 4K, 3840×2160@59.997, rotate270, 125%
    • Both report Adaptive Sync Support: false.
  • System suspend is disabled; no S3/s2idle is involved.

Steps to reproduce

  1. Two DP monitors, one rotated and scaled. GPU runtime PM enabled
    (/sys/bus/pci/devices/<gpu>/power/control = auto, the default).
  2. Leave the machine idle until COSMIC's screen-off turns the outputs off. With
    every CRTC off, amdgpu runtime-suspends the dGPU (BACO) after its 5 s
    autosuspend delay.
  3. Move the mouse or press a key to wake the screens. The dGPU runtime-resumes
    and the restore fails as below.

In my case the idle period came from switching a DisplayPort KVM to another
computer. The KVM keeps the connectors connected: switches without a screen-off
never trigger this, and no hotplug happens on a switch. So it should reproduce
without a KVM, though I haven't verified that.

Expected

The saved layout is restored when the screens wake.

Actual

The restore fails. The recovery disables all outputs and resets them to defaults.
DP-2 comes back landscape at default scale; DP-1 often stays dark until the
configuration is re-applied from Settings → Displays.

Logs

One occurrence (all four look identical):

15:28:39.229 kernel: amdgpu 0000:09:00.0: PSP is resuming...
15:28:39.648 kernel: amdgpu 0000:09:00.0: SMU is resumed successfully!
15:28:39.657 kernel: amdgpu 0000:09:00.0: [drm] DMUB hardware initialized: version=0x07002F00
15:28:40.041 cosmic-comp: Failed to destroy old mode property blob: No such file or directory (os error 2)
15:28:40.149 cosmic-comp: Failed to destroy old mode property blob: No such file or directory (os error 2)
15:28:40.253 cosmic-comp: Failed to set new config.
15:28:40.253 cosmic-comp: Unable to load output config: Failed to reset config
15:28:40.253 cosmic-comp: Failed to set new config.
15:28:40.485 cosmic-comp: Broken config, all outputs disabled. Resetting... [OutputConfig { mode: ((3440, 1440), Some(59973)), vrr: Enabled, scale: 1.0, transform: Normal, position: (0, 0), enabled: Disabled, max_bpc: Some(16), xwayland_primary: false }, OutputConfig { mode: ((3840, 2160), Some(59997)), vrr: Enabled, scale: 2.0, transform: Normal, position: (3440, 0), enabled: Disabled, max_bpc: Some(16), xwayland_primary: false }]
15:28:40.493 cosmic-comp: Failed to destroy old mode property blob: No such file or directory (os error 2)
15:28:40.585 cosmic-comp: Failed to set xwayland primary output: The provided output wasn't known to Xwayland

The underlying error only appears in the structured journal fields
(journalctl -o verbose), as F_ERR on the two Failed to set new config.
entries (src/config/mod.rs:482):

Failed to switch primary-plane scanout flags

Caused by:
    0: Failed to render outputs
    1: Output has no active mode
Failed to render outputs

Caused by:
    Output has no active mode

These are followed by Unable to load output config: Failed to reset config
(src/backend/kms/mod.rs:347) and Broken config, all outputs disabled
(src/config/mod.rs:435). The same sequence and F_ERR appear on all four
occurrences.

Observations

  • It only happens on screen wake after a GPU runtime resume. A screen-off/on
    with the GPU kept powered (amdgpu.runpm=0) logs the mode-blob message (benign,
    per the discussion in cosmic-comp loses DRM access after suspend/resume on AMD RDNA3 #2191) and restores the layout correctly.
  • The failure is "Output has no active mode" while re-applying the config right
    after the device re-initializes. The recovery then treats it as a broken config
    and disables every output. Retrying once the device has finished resuming, or
    falling back per output instead of resetting everything, would avoid the
    visible breakage.
  • Both outputs carry vrr: Enabled even though both report adaptive sync as
    unsupported. It's probably unrelated; noting it in case it isn't.

Workaround

amdgpu.runpm=0 on the kernel command line keeps the dGPU out of BACO, so no
runtime resume happens.

Related

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions