diff options
author | Minghao Chi <chi.minghao@zte.com.cn> | 2022-04-18 09:30:59 +0300 |
---|---|---|
committer | Nishanth Menon <nm@ti.com> | 2022-05-03 14:58:10 +0300 |
commit | 2b7042500cab7952bdbf4fe4a84de8712b418c36 (patch) | |
tree | 6e72c14f93ef4e26dd064e4823cd683b5e9034f9 /drivers/soc/ti | |
parent | b9e8a7d950ffed4cdd81e6457cfb8049227da2d1 (diff) | |
download | linux-2b7042500cab7952bdbf4fe4a84de8712b418c36.tar.xz |
soc: ti: pm33xx: using pm_runtime_resume_and_get instead of pm_runtime_get_sync
Using pm_runtime_resume_and_get is more appropriate
for simplifing code
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
Signed-off-by: Nishanth Menon <nm@ti.com>
Reviewed-by: Tony Lindgren <tony@aotmide.com>
Link: https://lore.kernel.org/r/20220418063059.2558074-1-chi.minghao@zte.com.cn
Diffstat (limited to 'drivers/soc/ti')
-rw-r--r-- | drivers/soc/ti/pm33xx.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/soc/ti/pm33xx.c b/drivers/soc/ti/pm33xx.c index 7bab4bbaf02d..ce09c42eaed2 100644 --- a/drivers/soc/ti/pm33xx.c +++ b/drivers/soc/ti/pm33xx.c @@ -555,11 +555,9 @@ static int am33xx_pm_probe(struct platform_device *pdev) #endif /* CONFIG_SUSPEND */ pm_runtime_enable(dev); - ret = pm_runtime_get_sync(dev); - if (ret < 0) { - pm_runtime_put_noidle(dev); + ret = pm_runtime_resume_and_get(dev); + if (ret < 0) goto err_pm_runtime_disable; - } ret = pm_ops->init(am33xx_do_sram_idle); if (ret) { |