Skip to contentSkip to conversation

reset: imx7: Correct polarity of MIPI CSI resets on i.MX8MQ

PATCH Applied [email protected] 4 participants 4 messages Jun 19 – Jul 2

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 reset: imx7: Correct polarity of MIPI CSI resets on i.MX8MQ

From: Robby Cai <[email protected]>

On i.MX8MQ, the MIPI CSI reset lines are active-low and not self-clearing. Writing '0' asserts reset and it remains asserted until explicitly deasserted by software.

This driver previously treated the MIPI CSI reset signals as active-high, which led to incorrect reset assert/deassert sequencing. This issue was exposed by commit 6d79bb8fd2aa ("media: imx8mq-mipi-csi2: Explicitly release reset").

Fix this by reflecting the correct reset polarity and ensuring proper reset handling.

Fixes c979dbf59987 ("reset: imx7: Add support for i.MX8MQ IP block variant")
Cc <[email protected]> # 6d79bb8fd2aa: media: imx8mq-mipi-csi2: Explicitly release reset

---

Changes in v3:
- Add Cc tag as suggested by Philipp Zabel
- Add R-b tag from Philipp Zabel

Link to v2: https://lore.kernel.org/imx/[email protected]/

Changes in v2:
- Drop the naming change in response to feedback from Krzysztof Kozlowski
- Refine the patch subject and commit message

Link to v1: https://lore.kernel.org/imx/[email protected]/

---
 drivers/reset/reset-imx7.c | 6 ++++++
 1 file changed, 6 insertions(+)
drivers/reset/reset-imx7.c +6 -0
index dd01fe11c5cb..a3cb8244d76a 100644
@@ -236,6 +236,12 @@ static int imx8mq_reset_set(struct reset_controller_dev *rcdev,
 
 	case IMX8MQ_RESET_PCIE_CTRL_APPS_EN:
 	case IMX8MQ_RESET_PCIE2_CTRL_APPS_EN:
+	case IMX8MQ_RESET_MIPI_CSI1_CORE_RESET:
+	case IMX8MQ_RESET_MIPI_CSI1_PHY_REF_RESET:
+	case IMX8MQ_RESET_MIPI_CSI1_ESC_RESET:
+	case IMX8MQ_RESET_MIPI_CSI2_CORE_RESET:
+	case IMX8MQ_RESET_MIPI_CSI2_PHY_REF_RESET:
+	case IMX8MQ_RESET_MIPI_CSI2_ESC_RESET:
 	case IMX8MQ_RESET_MIPI_DSI_PCLK_RESET_N:
 	case IMX8MQ_RESET_MIPI_DSI_ESC_RESET_N:
 	case IMX8MQ_RESET_MIPI_DSI_DPI_RESET_N:
Signature · 1 line
2.50.1
Reviewed-by on v3 1/1
#1 lore raw
Quoted 13 lines · On Fri, Jun 19, 2026 at 03:31:15PM +0800, [email protected] wrote:

[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

From: Robby Cai <[email protected]>

On i.MX8MQ, the MIPI CSI reset lines are active-low and not self-clearing. Writing '0' asserts reset and it remains asserted until explicitly deasserted by software.

This driver previously treated the MIPI CSI reset signals as active-high, which led to incorrect reset assert/deassert sequencing. This issue was exposed by commit 6d79bb8fd2aa ("media: imx8mq-mipi-csi2: Explicitly release reset").

Quoted 7 lines

Fix this by reflecting the correct reset polarity and ensuring proper reset handling.

Fixes c979dbf59987 ("reset: imx7: Add support for i.MX8MQ IP block variant")
Cc <[email protected]> # 6d79bb8fd2aa: media: imx8mq-mipi-csi2: Explicitly release reset
Quoted 40 lines

---

Changes in v3:
- Add Cc tag as suggested by Philipp Zabel
- Add R-b tag from Philipp Zabel

Link to v2: https://lore.kernel.org/imx/[email protected]/

Changes in v2:
- Drop the naming change in response to feedback from Krzysztof Kozlowski
- Refine the patch subject and commit message

Link to v1: https://lore.kernel.org/imx/[email protected]/

---
 drivers/reset/reset-imx7.c | 6 ++++++
 1 file changed, 6 insertions(+)
drivers/reset/reset-imx7.c +6 -1
index dd01fe11c5cb..a3cb8244d76a 100644
@@ -236,6 +236,12 @@ static int imx8mq_reset_set(struct reset_controller_dev *rcdev,
 
        case IMX8MQ_RESET_PCIE_CTRL_APPS_EN:
        case IMX8MQ_RESET_PCIE2_CTRL_APPS_EN:
+       case IMX8MQ_RESET_MIPI_CSI1_CORE_RESET:
+       case IMX8MQ_RESET_MIPI_CSI1_PHY_REF_RESET:
+       case IMX8MQ_RESET_MIPI_CSI1_ESC_RESET:
+       case IMX8MQ_RESET_MIPI_CSI2_CORE_RESET:
+       case IMX8MQ_RESET_MIPI_CSI2_PHY_REF_RESET:
+       case IMX8MQ_RESET_MIPI_CSI2_ESC_RESET:
        case IMX8MQ_RESET_MIPI_DSI_PCLK_RESET_N:
        case IMX8MQ_RESET_MIPI_DSI_ESC_RESET_N:
        case IMX8MQ_RESET_MIPI_DSI_DPI_RESET_N:
--

2.50.1

maintainer Applied
#3 lore raw
In reply to [email protected]
Quoted 6 lines · On Fr, 2026-06-19 at 15:31 +0800, [email protected] wrote:

From: Robby Cai <[email protected]>

On i.MX8MQ, the MIPI CSI reset lines are active-low and not self-clearing. Writing '0' asserts reset and it remains asserted until explicitly deasserted by software.

Quoted 7 lines

This driver previously treated the MIPI CSI reset signals as active-high, which led to incorrect reset assert/deassert sequencing. This issue was exposed by commit 6d79bb8fd2aa ("media: imx8mq-mipi-csi2: Explicitly release reset").

Fix this by reflecting the correct reset polarity and ensuring proper reset handling.

[...]

Applied to reset/fixes, thanks!

[1/1] reset: imx7: Correct polarity of MIPI CSI resets on i.MX8MQ

      https://git.kernel.org/pub/scm/linux/kernel/git/pza/linux.git/commit/?id=71827776667f

regards
Philipp