summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2013-02-24 08:46:48 +0100
committerTomasz Stanislawski <t.stanislaws@samsung.com>2013-03-13 10:49:34 +0100
commit5a770bbce1427f204f0c10da736918bbe9bc0b98 (patch)
treee7598e0871b39a340a3756705208974b575aba6b
parent65586a3b359cfca99b5b3a041968e50f466f25d0 (diff)
v4l2-drm-example: Don't enqueue initial page flip
There's no need to enqueue an initial page flip. Don't do it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
-rw-r--r--v4l2-drm-example/dmabuf-sharing.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/v4l2-drm-example/dmabuf-sharing.c b/v4l2-drm-example/dmabuf-sharing.c
index 6c7abe5..0483f27 100644
--- a/v4l2-drm-example/dmabuf-sharing.c
+++ b/v4l2-drm-example/dmabuf-sharing.c
@@ -482,9 +482,9 @@ int main(int argc, char *argv[])
&drm.con_id, 1, &drm.mode);
BYE_ON(ret, "drmModeSetCrtc failed: %s\n", ERRSTR);
- /* Enqueue the first buffer to DRM and all other buffers to V4L2 */
- drm_page_flip(&drm, &buffers[0]);
-
+ /* The first buffer is used for the initial CRTC frame buffer. Enqueue
+ * all others to V4L2.
+ */
for (unsigned int i = 1; i < s.buffer_count; ++i)
v4l2_queue_buffer(&v4l2, &buffers[i]);
@@ -499,7 +499,7 @@ int main(int argc, char *argv[])
/* buffer currently used by drm */
stream.v4l2 = &v4l2;
- stream.current_buffer = -1;
+ stream.current_buffer = 0;
stream.buffers = buffers;
stream.num_buffers = s.buffer_count;