lkml.org 
[lkml]   [2021]   [Mar]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH 1/3] media: i2c: imx219: Enable vflip and hflip controls on stream stop
Hi Prabhakar,

Thank you for the patch.

On Wed, Mar 10, 2021 at 12:20:12PM +0000, Lad Prabhakar wrote:
> Enable vflip and hflip controls in resume error path when streaming
> is stopped.
>
> Fixes: 1283b3b8f82b9 ("media: i2c: Add driver for Sony IMX219 sensor")
> Reported-by: Pavel Machek <pavel@denx.de>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> ---
> drivers/media/i2c/imx219.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/media/i2c/imx219.c b/drivers/media/i2c/imx219.c
> index 6e3382b85a90..f0cf1985a4dc 100644
> --- a/drivers/media/i2c/imx219.c
> +++ b/drivers/media/i2c/imx219.c
> @@ -1195,6 +1195,8 @@ static int __maybe_unused imx219_resume(struct device *dev)
> error:
> imx219_stop_streaming(imx219);
> imx219->streaming = false;
> + __v4l2_ctrl_grab(imx219->vflip, false);
> + __v4l2_ctrl_grab(imx219->hflip, false);

It's not very nice to do this manually in imx219_resume(). Shouldn't we
move the __v4l2_ctrl_grab() calls from imx219_set_stream() to
imx219_start_streaming() and imx219_stop_streaming() instead ?

>
> return ret;
> }

--
Regards,

Laurent Pinchart
\
 
 \ /
  Last update: 2021-03-10 13:46    [W:0.060 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site