diff options
author | Ian Jamison <ian.dev@arkver.com> | 2017-12-01 21:53:50 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-12-08 18:38:44 +0300 |
commit | 678856299c0db53c47bfcbedda7921d878a78be5 (patch) | |
tree | 3dd2ce7c8931b69f606041cabaaedc39a47ea9f4 /drivers | |
parent | 8fc58186bb41ff8789ad9e993c03a23d67698709 (diff) | |
download | linux-678856299c0db53c47bfcbedda7921d878a78be5.tar.xz |
media: imx: Remove incorrect check for queue state in start/stop_streaming
It is possible to call STREAMON without the minimum number of
buffers queued. In this case the vb2_queue state will be set to
streaming but the start_streaming vb2_op will not be called.
Later when enough buffers are queued, start_streaming will
be called but vb2_is_streaming will already return true.
Also removed the queue state check in stop_streaming since it's
not valid there either.
Signed-off-by: Ian Jamison <ian.dev@arkver.com>
Reviewed-by: Steve Longerbeam <steve_longerbeam@mentor.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/media/imx/imx-media-capture.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/staging/media/imx/imx-media-capture.c b/drivers/staging/media/imx/imx-media-capture.c index ea145bafb880..7b6763802db8 100644 --- a/drivers/staging/media/imx/imx-media-capture.c +++ b/drivers/staging/media/imx/imx-media-capture.c @@ -449,9 +449,6 @@ static int capture_start_streaming(struct vb2_queue *vq, unsigned int count) unsigned long flags; int ret; - if (vb2_is_streaming(vq)) - return 0; - ret = imx_media_pipeline_set_stream(priv->md, &priv->src_sd->entity, true); if (ret) { @@ -480,9 +477,6 @@ static void capture_stop_streaming(struct vb2_queue *vq) unsigned long flags; int ret; - if (!vb2_is_streaming(vq)) - return; - spin_lock_irqsave(&priv->q_lock, flags); priv->stop = true; spin_unlock_irqrestore(&priv->q_lock, flags); |