GNOME Bugzilla – Bug 608042
[camerabin-example] v4l2 device busy after setting back to ready and changing the mode
Last modified: 2010-01-28 13:16:34 UTC
gst-plugins-bad/tests/examples/camerabin LIBV4L2_LOG_FILENAME=/tmp/v4l2.log gst-plugin-bad/tests/examples/camerabin/gst-camera change the resolution *bang* - I wonder about the "unknown munmap" - as we have 2 buffers mapped we should be able to munmap 2 - maybe we get the device busy because of pedning buffers (http://www.linuxtv.org/downloads/video4linux/API/V4L2_API/spec-single/v4l2.html#vidioc-g-fmt) ... request == VIDIOC_DQBUF result == 0 request == VIDIOC_QBUF result == 0 request == VIDIOC_STREAMOFF result == 0 libv4l2: v4l2 unknown munmap 0xb6d45000, 38400 libv4l2: v4l2 unknown munmap 0xb6d3b000, 38400 request == VIDIOC_G_FMT pixelformat: YUYV 160x120 field: 1 bytesperline: 320 imagesize38400 colorspace: 8, priv: 0 result == 0 VIDIOC_S_FMT app requesting: YUYV libv4l2: error setting pixformat: Device or resource busy request == VIDIOC_S_FMT pixelformat: YUYV 160x120 field: 1 bytesperline: 320 imagesize38400 colorspace: 8, priv: 0 result == -1 (Device or resource busy) VIDIOC_S_FMT app requesting: YUYV libv4l2: error setting pixformat: Device or resource busy request == VIDIOC_S_FMT pixelformat: YUYV 160x120 field: 1 bytesperline: 320 imagesize38400 colorspace: 8, priv: 0 result == -1 (Device or resource busy)
This might be a driver problem. Lower priority therefore. With my cam at home I have to run it as LD_PRELOAD=/usr/lib/libv4l/v4l2convert.so ./tests/examples/camerabin/gst-camera and I only get some warnings. Warning: Internal GStreamer error: clock problem. Please file a bug at http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer. Warning: Internal GStreamer error: clock problem. Please file a bug at http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer.
This was a race in the gst-camera test app. Fixed among other things. commit 0713748e1b63dea9298b00b10b8acffb01170368 Author: Stefan Kost <ensonic@users.sf.net> Date: Thu Jan 28 15:00:32 2010 +0200 camerabin-example: cleanups for mainloop and state-changes. Fixes #608042 Start camerabin via idle handler to have the mainloop already running. Avoid some unnecessary state changes. Cleanup the bus usage when restarting.