mirror of
https://github.com/torvalds/linux.git
synced 2026-05-24 07:03:03 +02:00
media: mipi-csis: Add check for clk_enable()
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>
This commit is contained in:
parent
7b1ec3e389
commit
125ad1aeec
|
|
@ -940,13 +940,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;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user