staging: bcm2835-camera: Set the field value within each buffer
authorDave Stevenson <dave.stevenson@raspberrypi.org>
Tue, 15 Jan 2019 16:32:33 +0000 (16:32 +0000)
committerpopcornmix <popcornmix@gmail.com>
Mon, 13 May 2019 23:08:18 +0000 (00:08 +0100)
Fixes a v4l2-compliance failure
v4l2-test-buffers.cpp(415): g_field() == V4L2_FIELD_ANY

The driver only ever produces progresive frames, so field should
always be set to V4L2_FIELD_NONE.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c

index dbdc4e8..a8f3ce5 100644 (file)
@@ -443,6 +443,7 @@ static void buffer_cb(struct vchiq_mmal_instance *instance,
        }
        dev->capture.last_timestamp = buf->vb.vb2_buf.timestamp;
        buf->vb.sequence = dev->capture.sequence++;
+       buf->vb.field = V4L2_FIELD_NONE;
 
        vb2_set_plane_payload(&buf->vb.vb2_buf, 0, mmal_buf->length);
        if (mmal_buf->mmal_flags & MMAL_BUFFER_HEADER_FLAG_KEYFRAME)