path: root/drivers
diff options
authorPhilipp Zabel <p.zabel@pengutronix.de>2014-07-18 12:22:41 +0200
committerKamil Debski <k.debski@samsung.com>2014-08-05 17:16:51 +0200
commita3703d960d24f30f2425c2cd892885e04778ad56 (patch)
tree52b73ce7d0caf240cf3a382ba1a0662dc9a9b505 /drivers
parent0df36d0dcc88af0958b1e9e06f2bd1781111eb6a (diff)
coda: lock capture frame size to output frame size when streaming
As soon as the output queue is streaming, let try_fmt on the capture side only allow the frame size that was set on the output side. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Kamil Debski <k.debski@samsung.com>
Diffstat (limited to 'drivers')
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/platform/coda.c b/drivers/media/platform/coda.c
index 898eb3dbb8da..f1cf44a5aa3c 100644
--- a/drivers/media/platform/coda.c
+++ b/drivers/media/platform/coda.c
@@ -719,6 +719,9 @@ static int coda_try_fmt_vid_cap(struct file *file, void *priv,
if (!codec)
return -EINVAL;
+ f->fmt.pix.width = q_data_src->width;
+ f->fmt.pix.height = q_data_src->height;
} else {
/* Otherwise determine codec by encoded format, if possible */
codec = coda_find_codec(ctx->dev, V4L2_PIX_FMT_YUV420,

Privacy Policy