media: venus: core: change clk enable and disable order in resume and suspend
Currently video driver is voting after clk enable and un voting
before clk disable. This is incorrect, video driver should vote
before clk enable and unvote after clk disable.
Corrected this by changing the order of clk enable and clk disable.
suspend")
Fixes: 07f8f22a33
("media: venus: core: remove CNOC voting while device
Signed-off-by: Mansur Alisha Shaik <mansur@codeaurora.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
This commit is contained in:
parent
de04408fd1
commit
21926d466e
|
@ -355,13 +355,16 @@ static __maybe_unused int venus_runtime_suspend(struct device *dev)
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
|
if (pm_ops->core_power) {
|
||||||
|
ret = pm_ops->core_power(dev, POWER_OFF);
|
||||||
|
if (ret)
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
ret = icc_set_bw(core->cpucfg_path, 0, 0);
|
ret = icc_set_bw(core->cpucfg_path, 0, 0);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
if (pm_ops->core_power)
|
|
||||||
ret = pm_ops->core_power(dev, POWER_OFF);
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -371,16 +374,16 @@ static __maybe_unused int venus_runtime_resume(struct device *dev)
|
||||||
const struct venus_pm_ops *pm_ops = core->pm_ops;
|
const struct venus_pm_ops *pm_ops = core->pm_ops;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
|
ret = icc_set_bw(core->cpucfg_path, 0, kbps_to_icc(1000));
|
||||||
|
if (ret)
|
||||||
|
return ret;
|
||||||
|
|
||||||
if (pm_ops->core_power) {
|
if (pm_ops->core_power) {
|
||||||
ret = pm_ops->core_power(dev, POWER_ON);
|
ret = pm_ops->core_power(dev, POWER_ON);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = icc_set_bw(core->cpucfg_path, 0, kbps_to_icc(1000));
|
|
||||||
if (ret)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
return hfi_core_resume(core, false);
|
return hfi_core_resume(core, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue