|
|
@@ -132,12 +132,15 @@ static int vimc_cap_s_fmt_vid_cap(struct file *file, void *priv,
|
|
|
struct v4l2_format *f)
|
|
|
{
|
|
|
struct vimc_cap_device *vcap = video_drvdata(file);
|
|
|
+ int ret;
|
|
|
|
|
|
/* Do not change the format while stream is on */
|
|
|
if (vb2_is_busy(&vcap->queue))
|
|
|
return -EBUSY;
|
|
|
|
|
|
- vimc_cap_try_fmt_vid_cap(file, priv, f);
|
|
|
+ ret = vimc_cap_try_fmt_vid_cap(file, priv, f);
|
|
|
+ if (ret)
|
|
|
+ return ret;
|
|
|
|
|
|
dev_dbg(vcap->dev, "%s: format update: "
|
|
|
"old:%dx%d (0x%x, %d, %d, %d, %d) "
|