]> git.baikalelectronics.ru Git - kernel.git/commitdiff
media: imx: imx7_mipi_csis: Power off the source when stopping streaming
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Tue, 10 Mar 2020 16:06:24 +0000 (17:06 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 17 Apr 2020 08:50:01 +0000 (10:50 +0200)
[ Upstream commit d9cbcd82bfd7b3cc4b4ab5ab71746b8f13abc7e5 ]

The .s_stream() implementation incorrectly powers on the source when
stopping the stream. Power it off instead.

Fixes: acc1dfc71784 ("media: staging/imx7: add MIPI CSI-2 receiver subdev for i.MX7")
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Rui Miguel Silva <rmfrfs@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/staging/media/imx/imx7-mipi-csis.c

index e50b1f88e25b579569c6afa91604e0b95eb205bc..6f628195c4daa3217f5ebb83e75a7ef24ac3ab8b 100644 (file)
@@ -579,7 +579,7 @@ static int mipi_csis_s_stream(struct v4l2_subdev *mipi_sd, int enable)
                state->flags |= ST_STREAMING;
        } else {
                v4l2_subdev_call(state->src_sd, video, s_stream, 0);
-               ret = v4l2_subdev_call(state->src_sd, core, s_power, 1);
+               ret = v4l2_subdev_call(state->src_sd, core, s_power, 0);
                mipi_csis_stop_stream(state);
                state->flags &= ~ST_STREAMING;
                if (state->debug)