From 6bf9f4bd77a4c6cce8786893feea7d601a6e6030 Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Wed, 8 Apr 2020 12:34:40 -0400 Subject: [PATCH] v4l2bufferpool: request the maximum number of buffers for USERPTR This is to match what we now do for DMABuf importation. --- sys/v4l2/gstv4l2bufferpool.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/v4l2/gstv4l2bufferpool.c b/sys/v4l2/gstv4l2bufferpool.c index a362413645..5de5af2289 100644 --- a/sys/v4l2/gstv4l2bufferpool.c +++ b/sys/v4l2/gstv4l2bufferpool.c @@ -821,9 +821,10 @@ gst_v4l2_buffer_pool_start (GstBufferPool * bpool) can_allocate = GST_V4L2_ALLOCATOR_CAN_ALLOCATE (pool->vallocator, USERPTR); - GST_DEBUG_OBJECT (pool, "requesting %d USERPTR buffers", min_buffers); + GST_DEBUG_OBJECT (pool, "requesting %d USERPTR import slots", + max_buffers); - count = gst_v4l2_allocator_start (pool->vallocator, min_buffers, + count = gst_v4l2_allocator_start (pool->vallocator, max_buffers, V4L2_MEMORY_USERPTR); /* There is no rational to not get what we asked */