mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-26 04:25:27 +08:00
drm/exynos: Use pm_runtime_resume_and_get() to replace open coding
use pm_runtime_resume_and_get() to replace pm_runtime_get_sync and pm_runtime_put_noidle to avoid continuing to increase the refcount when pm_runtime_get_sync fails. Signed-off-by: Tian Tao <tiantao6@hisilicon.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:
parent
c707b73f0c
commit
a89b6c8f86
@ -268,11 +268,9 @@ static void mic_pre_enable(struct drm_bridge *bridge)
|
||||
if (mic->enabled)
|
||||
goto unlock;
|
||||
|
||||
ret = pm_runtime_get_sync(mic->dev);
|
||||
if (ret < 0) {
|
||||
pm_runtime_put_noidle(mic->dev);
|
||||
ret = pm_runtime_resume_and_get(mic->dev);
|
||||
if (ret < 0)
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
mic_set_path(mic, 1);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user