On Sun, Mar 02, 2025 at 02:58:20PM GMT, Jonathan Gray wrote: > On Sat, Mar 01, 2025 at 06:43:17PM +0100, Marcus Glocker wrote: > > >Synopsis: ThinkPad X1 screen turns occasionally black > > >Category: video inteldrm > > >Environment: > > System : OpenBSD 7.6 > > Details : OpenBSD 7.6-current (GENERIC.MP) #14: Sat Mar 1 14:53:36 > > CET 2025 > > ha...@x1.nazgul.ch:/sys/arch/amd64/compile/GENERIC.MP > > > > Architecture: OpenBSD.amd64 > > Machine : amd64 > > >Description: > > In X11, the screen of my ThinkPad X1 will occasionally turn black. > > The only way to recover, is to switch to console, and back to X11. > > After that, follwing lines are printed on the console: > > > > drm_gem_plane_helper_prepare_fb: explicit fence not handled > > drm_gem_plane_helper_prepare_fb: explicit fence not handled > > what are you running in X when this happens?
Basically not much. I run WindowMaker with some docker apps, two xterms, and xconsole. The issue so far appeared when the machine was idle. First I thought the issue is triggered by the hardware screen saver, but that got activated a few times today, and the issue didn't re-appear yet. I have currently no idea how to trigger the issue, since it appears very intermittently. For example, today the machine was used the entire day, with some long idle periods in between, and the issue didn't re-appear yet. > try this: Thanks for the diff. But based on my above explanation it's pretty hard to find out whether the diff makes a difference. Maybe I can find out a pattern over time. > Index: sys/dev/pci/drm/drm_gem_atomic_helper.c > =================================================================== > RCS file: /cvs/src/sys/dev/pci/drm/drm_gem_atomic_helper.c,v > diff -u -p -r1.2 drm_gem_atomic_helper.c > --- sys/dev/pci/drm/drm_gem_atomic_helper.c 1 Jan 2023 01:34:34 -0000 > 1.2 > +++ sys/dev/pci/drm/drm_gem_atomic_helper.c 2 Mar 2025 03:28:20 -0000 > @@ -20,14 +20,13 @@ drm_gem_plane_helper_prepare_fb(struct d > obj = dps->fb->obj[0]; > if (obj == NULL) > return -EINVAL; > - if (dps->fence) { > - printf("%s: explicit fence not handled\n", __func__); > - return -EINVAL; > - } > r = dma_resv_get_singleton(obj->resv, DMA_RESV_USAGE_WRITE, &f); > if (r) > return r; > - dps->fence = f; > + if (dps->fence) > + dma_fence_put(f); > + else > + dps->fence = f; > } > > return 0;