media: mipi-csis: Add check for clk_enable()
BugLink: https://bugs.launchpad.net/bugs/2111953
[ Upstream commit 125ad1aeec77eb55273b420be6894b284a01e4b6 ]
Add check for the return value of clk_enable() to gurantee the success.
Fixes: b5f1220d58 ("[media] v4l: Add v4l2 subdev driver for S5P/EXYNOS4 MIPI-CSI receivers")
Signed-off-by: Jiasheng Jiang <jiashengjiangcool@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Manuel Diewald <manuel.diewald@canonical.com>
Signed-off-by: Mehmet Basaran <mehmet.basaran@canonical.com>
This commit is contained in:
committed by
Mehmet Basaran
parent
07bd1308f7
commit
394d1253b5
@@ -939,13 +939,19 @@ static int s5pcsis_pm_resume(struct device *dev, bool runtime)
|
||||
state->supplies);
|
||||
goto unlock;
|
||||
}
|
||||
clk_enable(state->clock[CSIS_CLK_GATE]);
|
||||
ret = clk_enable(state->clock[CSIS_CLK_GATE]);
|
||||
if (ret) {
|
||||
phy_power_off(state->phy);
|
||||
regulator_bulk_disable(CSIS_NUM_SUPPLIES,
|
||||
state->supplies);
|
||||
goto unlock;
|
||||
}
|
||||
}
|
||||
if (state->flags & ST_STREAMING)
|
||||
s5pcsis_start_stream(state);
|
||||
|
||||
state->flags &= ~ST_SUSPENDED;
|
||||
unlock:
|
||||
unlock:
|
||||
mutex_unlock(&state->lock);
|
||||
return ret ? -EAGAIN : 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user