Skip to content

Commit 7b12ab0

Browse files
Laurentiu Palcuhverkuil
authored andcommitted
media: nxp: imx8-isi: fix v4l2-compliance test errors
Running the v4l2-compliance (1.27.0-5208, SHA: af114250d48d) on the m2m device fails on the MMAP streaming tests, with the following messages: fail: v4l2-test-buffers.cpp(240): g_field() == V4L2_FIELD_ANY fail: v4l2-test-buffers.cpp(1508): buf.qbuf(node) Apparently, the driver does not properly set the field member of vb2_v4l2_buffer struct, returning the default V4L2_FIELD_ANY value which is against the guidelines. Fixes: cf21f32 ("media: nxp: Add i.MX8 ISI driver") Signed-off-by: Laurentiu Palcu <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Laurent Pinchart <[email protected]> Signed-off-by: Hans Verkuil <[email protected]>
1 parent 2762eab commit 7b12ab0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/media/platform/nxp/imx8-isi/imx8-isi-video.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -861,6 +861,7 @@ int mxc_isi_video_buffer_prepare(struct mxc_isi_dev *isi, struct vb2_buffer *vb2
861861
const struct mxc_isi_format_info *info,
862862
const struct v4l2_pix_format_mplane *pix)
863863
{
864+
struct vb2_v4l2_buffer *v4l2_buf = to_vb2_v4l2_buffer(vb2);
864865
unsigned int i;
865866

866867
for (i = 0; i < info->mem_planes; i++) {
@@ -875,6 +876,8 @@ int mxc_isi_video_buffer_prepare(struct mxc_isi_dev *isi, struct vb2_buffer *vb2
875876
vb2_set_plane_payload(vb2, i, size);
876877
}
877878

879+
v4l2_buf->field = pix->field;
880+
878881
return 0;
879882
}
880883

0 commit comments

Comments
 (0)