Commit 365f3bfc authored by Ezequiel Garcia's avatar Ezequiel Garcia Committed by Mauro Carvalho Chehab

media: rockchip/vpu: Use v4l2_m2m_buf_copy_metadata

Use the recently introduced v4l2_m2m_buf_copy_metadata helper
and get rid of some code.
Signed-off-by: default avatarEzequiel Garcia <ezequiel@collabora.com>
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+samsung@kernel.org>
parent cf760c4b
...@@ -58,14 +58,7 @@ static void rockchip_vpu_job_finish(struct rockchip_vpu_dev *vpu, ...@@ -58,14 +58,7 @@ static void rockchip_vpu_job_finish(struct rockchip_vpu_dev *vpu,
src->sequence = ctx->sequence_out++; src->sequence = ctx->sequence_out++;
dst->sequence = ctx->sequence_cap++; dst->sequence = ctx->sequence_cap++;
dst->field = src->field; v4l2_m2m_buf_copy_metadata(src, dst, true);
if (src->flags & V4L2_BUF_FLAG_TIMECODE)
dst->timecode = src->timecode;
dst->vb2_buf.timestamp = src->vb2_buf.timestamp;
dst->flags &= ~(V4L2_BUF_FLAG_TSTAMP_SRC_MASK |
V4L2_BUF_FLAG_TIMECODE);
dst->flags |= src->flags & (V4L2_BUF_FLAG_TSTAMP_SRC_MASK |
V4L2_BUF_FLAG_TIMECODE);
avail_size = vb2_plane_size(&dst->vb2_buf, 0) - avail_size = vb2_plane_size(&dst->vb2_buf, 0) -
ctx->vpu_dst_fmt->header_size; ctx->vpu_dst_fmt->header_size;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment