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 741134 - v4l2: CREATE_BUF support is broken
v4l2: CREATE_BUF support is broken
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
git master
Other Linux
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-12-04 21:54 UTC by Nicolas Dufresne (ndufresne)
Modified: 2014-12-04 22:07 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Nicolas Dufresne (ndufresne) 2014-12-04 21:54:35 UTC
CREATE_BUF support has been broken for a long time. I can't recall, because it's recent that a very commonly used driver (UVC) supports that. This is not a regression fix, but still just a bug fix. I think we should consider it or 1.4. I'll post the patches here, I'm open for comment.
Comment 1 Nicolas Dufresne (ndufresne) 2014-12-04 22:05:47 UTC
Fixed in master:
commit 319efc3e202d521acf521bfd94f97852afe2c602
Author: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Date:   Wed Dec 3 17:07:49 2014 -0500

    v4l2pool: Fix CREATE_BUFS support for capture
    
    This patch fixes CREATE_BUFS support for capture devices. Initially we
    would only try and allocate more buffers when the copy threshold
    is reached. When the threshold was not set (needed) it would never
    happen. Another problem is that on capture side, acquire returns
    filled buffer, hence need to pool. We need to set a special flag to
    force allocation to happen.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=741134

commit b80edd2ee2e4b8c6154c37ed115fee90ff381053
Author: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Date:   Wed Dec 3 16:27:59 2014 -0500

    v4l2allocator: Fix CREATE_BUF probing
    
    Current for every memory type we where probing MMAP CREATE_BUFS ioct.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=741134
Comment 2 Nicolas Dufresne (ndufresne) 2014-12-04 22:07:53 UTC
Remains to decide if we backport of not. Some testing would be nice. for those who'd like to test, Kernel < 3.15.2 has no CREATE_BUF in UVC. A pipeline that typically stalls without that:

gst-launch-1.0 v4l2src ! video/x-raw,framerate=30/1 ! queue min-threshold-buffers=16 ! xvimagesink sync=false