summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJacopo Mondi <jacopo.mondi@ideasonboard.com>2024-06-17 18:11:26 +0200
committerLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>2024-06-19 18:42:56 +0200
commitf6d64d0d2897ed4e85ac00afe43e45c8b8fc0c44 (patch)
treec0674c88f09a3c8e500879560cc3067dea4b328d
parentmedia: rcar-csi2: Disable runtime_pm in probe error (diff)
downloadlinux-f6d64d0d2897ed4e85ac00afe43e45c8b8fc0c44.tar.xz
linux-f6d64d0d2897ed4e85ac00afe43e45c8b8fc0c44.zip
media: rcar-csi2: Cleanup subdevice in remove()
Cleanup the V4L2 subdevice in the driver's remove function to ensure its async connection are freed, and guarantee in future that the subdev active state is cleaned up. Fixes: 769afd212b16 ("media: rcar-csi2: add Renesas R-Car MIPI CSI-2 receiver driver") Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Tested-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Link: https://lore.kernel.org/r/20240617161135.130719-4-jacopo.mondi@ideasonboard.com Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
-rw-r--r--drivers/media/platform/renesas/rcar-csi2.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/platform/renesas/rcar-csi2.c b/drivers/media/platform/renesas/rcar-csi2.c
index 249e58c77176..2d464e43a5be 100644
--- a/drivers/media/platform/renesas/rcar-csi2.c
+++ b/drivers/media/platform/renesas/rcar-csi2.c
@@ -1938,6 +1938,7 @@ static void rcsi2_remove(struct platform_device *pdev)
v4l2_async_nf_unregister(&priv->notifier);
v4l2_async_nf_cleanup(&priv->notifier);
v4l2_async_unregister_subdev(&priv->subdev);
+ v4l2_subdev_cleanup(&priv->subdev);
pm_runtime_disable(&pdev->dev);