summaryrefslogtreecommitdiff
path: root/drivers/media/platform/exynos4-is
diff options
context:
space:
mode:
authorChuhong Yuan <hslester96@gmail.com>2020-05-28 09:41:47 +0300
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-07-04 13:44:12 +0300
commit18ffec750578f7447c288647d7282c7d12b1d969 (patch)
treea617eb18c0bb9dd0143a2b2da85965a5650bd4d4 /drivers/media/platform/exynos4-is
parent875c0d75954f022b2118f8dbfe57b96021de383b (diff)
downloadlinux-18ffec750578f7447c288647d7282c7d12b1d969.tar.xz
media: exynos4-is: Add missed check for pinctrl_lookup_state()
fimc_md_get_pinctrl() misses a check for pinctrl_lookup_state(). Add the missed check to fix it. Fixes: 4163851f7b99 ("[media] s5p-fimc: Use pinctrl API for camera ports configuration]") Signed-off-by: Chuhong Yuan <hslester96@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/platform/exynos4-is')
-rw-r--r--drivers/media/platform/exynos4-is/media-dev.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/platform/exynos4-is/media-dev.c b/drivers/media/platform/exynos4-is/media-dev.c
index 96e336b19cc3..16dd660137a8 100644
--- a/drivers/media/platform/exynos4-is/media-dev.c
+++ b/drivers/media/platform/exynos4-is/media-dev.c
@@ -1270,6 +1270,9 @@ static int fimc_md_get_pinctrl(struct fimc_md *fmd)
pctl->state_idle = pinctrl_lookup_state(pctl->pinctrl,
PINCTRL_STATE_IDLE);
+ if (IS_ERR(pctl->state_idle))
+ return PTR_ERR(pctl->state_idle);
+
return 0;
}