During start_streaming of output, it checks src_bufs_cnt compared
with pb_count. But it is only meaningful for MMAP memory. So this
patch fixes to set src_bufs_cnt with requested buffer for non MMAP
memory.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
mfc_err("error in vb2_reqbufs() for E(S)\n");
return ret;
}
+ if (reqbufs->memory != V4L2_MEMORY_MMAP)
+ ctx->src_bufs_cnt = reqbufs->count;
ctx->output_state = QUEUE_BUFS_REQUESTED;
} else {
mfc_err("invalid buf type\n");
vb2_dma_contig_plane_dma_addr(vb, 0);
ctx->src_bufs[i].cookie.raw.chroma =
vb2_dma_contig_plane_dma_addr(vb, 1);
- ctx->src_bufs_cnt++;
+ if (vb->v4l2_buf.memory == V4L2_MEMORY_MMAP)
+ ctx->src_bufs_cnt++;
} else {
mfc_err("invalid queue type: %d\n", vq->type);
return -EINVAL;