]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
media: imx8mq-mipi-csi2: Explicitly release reset
authorGuoniu Zhou <guoniu.zhou@nxp.com>
Fri, 5 Dec 2025 09:07:45 +0000 (17:07 +0800)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Tue, 24 Mar 2026 21:14:44 +0000 (22:14 +0100)
Call reset_control_deassert() to explicitly release reset to make sure
reset bits are cleared since platform like i.MX8ULP can't clear reset
bits automatically.

Reviewed-by: Frank Li <Frank.Li@nxp.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Guoniu Zhou <guoniu.zhou@nxp.com>
Link: https://patch.msgid.link/20251205-csi2_imx8ulp-v10-3-190cdadb20a3@nxp.com
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
drivers/media/platform/nxp/imx8mq-mipi-csi2.c

index be945da9bb5eb5830671ea73e9f8fe009a34c1cc..e4fe7e3bd769b14b583a2520b1f97e087eb7a13a 100644 (file)
@@ -339,18 +339,14 @@ static int imx8mq_mipi_csi_sw_reset(struct csi_state *state)
 {
        int ret;
 
-       /*
-        * these are most likely self-clearing reset bits. to make it
-        * more clear, the reset-imx7 driver should implement the
-        * .reset() operation.
-        */
        ret = reset_control_assert(state->rst);
        if (ret < 0) {
                dev_err(state->dev, "Failed to assert resets: %d\n", ret);
                return ret;
        }
 
-       return 0;
+       /* Explicitly release reset to make sure reset bits are cleared. */
+       return reset_control_deassert(state->rst);
 }
 
 static void imx8mq_mipi_csi_set_params(struct csi_state *state)