After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 797297 - glcontext: DRM context is not being finalized if no display is connected
glcontext: DRM context is not being finalized if no display is connected
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
1.14.x
Other Linux
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-10-17 07:03 UTC by Eugen Klim
Modified: 2018-11-03 12:11 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
a simple python script which consequently creates pipelines, logs with and without the issue (2.50 KB, application/gzip)
2018-10-17 07:03 UTC, Eugen Klim
  Details
Here is the patch, which closes drm descriptor and fixes context leaks in window_gbm (2.44 KB, patch)
2018-10-18 07:44 UTC, Eugen Klim
none Details | Review

Description Eugen Klim 2018-10-17 07:03:09 UTC
Created attachment 373948 [details]
a simple python script which consequently creates pipelines, logs with and without the issue

I use gl elements from gstreamer 1.14 with this [1] patch on a headless system (linux 4.17, mesa 18.2).

It initializes and runs fine, but when I try to destroy the pipeline and build a new one, old context persists, and newly created context is being created as a software (llvmpipe) context (it seems due to the previous one is not deleted).

Under wayland and X11 context is being finalized and (re)created fine. I've attached a simple python script to test the issue, error log (from a headless run) and a normal log (from under wayland)

[1] https://bugzilla.gnome.org/show_bug.cgi?id=794716
Comment 1 Eugen Klim 2018-10-17 08:59:06 UTC
Ok, the reason is that nobody closes the drm_fd, opened in `gst-libs/gl/gbm/gstgldisplay_gbm.c:392`.

The other issue is that context ref counter is incremented one extra time somewhere, so the display finalizer is never called.
Comment 2 Eugen Klim 2018-10-18 07:44:50 UTC
Created attachment 373958 [details] [review]
Here is the patch, which closes drm descriptor and fixes context leaks in window_gbm
Comment 3 Eugen Klim 2018-10-18 07:47:40 UTC
Also this should be merged in master/1.15, right after this one:

https://bugzilla.gnome.org/show_bug.cgi?id=794716
Comment 4 GStreamer system administrator 2018-11-03 12:11:04 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/issues/494.