Skip to content
This repository has been archived by the owner on Nov 1, 2021. It is now read-only.

Re-enabling output sometimes fail #2150

Closed
jbeich opened this issue May 1, 2020 · 2 comments · Fixed by #2168
Closed

Re-enabling output sometimes fail #2150

jbeich opened this issue May 1, 2020 · 2 comments · Fixed by #2168

Comments

@jbeich
Copy link
Contributor

jbeich commented May 1, 2020

Regressed by #2118. See debug log.

Steps to reproduce

  1. Start Sway
  2. Disable display
  3. Enable display
  4. Repeat (2) and (3) until black screen

Actual result

Display wakes up but with no signal goes back to sleep. On console:

[main.c:168] Destroying output DP-1 (...)
[ERROR] [backend/drm/renderer.c:379] Tried to acquire an FB with a NULL BO
[ERROR] [backend/drm/renderer.c:379] Tried to acquire an FB with a NULL BO
[ERROR] [backend/drm/drm.c:754] Failed to initialize renderer on connector 'DP-1': initial page-flip failed
[ERROR] [backend/drm/drm.c:835] Failed to initialize renderer for plane
[sway/config/output.c:423] Failed to commit output DP-1
[ERROR] [backend/drm/renderer.c:379] Tried to acquire an FB with a NULL BO

Expected result

Display works like before sleep

Environment

$ cc --version
FreeBSD clang version 10.0.0 (git@github.com:llvm/llvm-project.git llvmorg-10.0.0-0-gd32170dbd5b)
Target: x86_64-unknown-freebsd13.0
Thread model: posix
InstalledDir: /usr/bin

$ sway --version
sway version 1.2-rc1-334-g5e5e5f2e
wlroots version 0.10.0-107-g61d6408f

$ cat /tmp/sway.conf
bindsym Ctrl+Alt+BackSpace exit
bindsym Down output * dpms off
bindsym Up output * dpms on

output * background #15c6ac solid_color
emersion added a commit to emersion/wlroots that referenced this issue May 7, 2020
dealloc_crtc was destroying GBM surfaces, but the cursor_enabled flag
was left as-is. When re-enabling the output, atomic_crtc_pageflip would
try enabling the cursor plane, but would fail because no framebuffer is
available.

Closes: swaywm#2150
@emersion
Copy link
Member

emersion commented May 7, 2020

Can you try #2168?

@jbeich
Copy link
Contributor Author

jbeich commented May 7, 2020

Can you try #2168?

After applying I can't reproduce anymore. Thanks!

ddevault pushed a commit that referenced this issue May 12, 2020
dealloc_crtc was destroying GBM surfaces, but the cursor_enabled flag
was left as-is. When re-enabling the output, atomic_crtc_pageflip would
try enabling the cursor plane, but would fail because no framebuffer is
available.

Closes: #2150
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

Successfully merging a pull request may close this issue.

2 participants