summaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorZheyu Ma <zheyuma97@gmail.com>2022-05-10 13:48:52 +0200
committerMauro Carvalho Chehab <mchehab@kernel.org>2024-04-29 13:06:33 +0200
commit9bc92332cc3f06fda3c6e2423995ca2da0a7ec9a (patch)
tree3537f9833fa5a0c385caf454f7abc9e707650d3c /drivers/media
parentmedia: lgdt3306a: Add a check against null-pointer-def (diff)
downloadlinux-9bc92332cc3f06fda3c6e2423995ca2da0a7ec9a.tar.xz
linux-9bc92332cc3f06fda3c6e2423995ca2da0a7ec9a.zip
media: imx214: Fix the error handling in imx214_probe()
The driver should disable regulators when fails to probe. Link: https://lore.kernel.org/linux-media/20220510114852.1719018-1-zheyuma97@gmail.com Signed-off-by: Zheyu Ma <zheyuma97@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/i2c/imx214.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/i2c/imx214.c b/drivers/media/i2c/imx214.c
index 10b6ad66d126..4962cfe7c83d 100644
--- a/drivers/media/i2c/imx214.c
+++ b/drivers/media/i2c/imx214.c
@@ -1114,6 +1114,7 @@ free_ctrl:
v4l2_ctrl_handler_free(&imx214->ctrls);
error_power_off:
pm_runtime_disable(imx214->dev);
+ regulator_bulk_disable(IMX214_NUM_SUPPLIES, imx214->supplies);
return ret;
}