Skip to content

Commit 915bf27

Browse files
plbossartvinodkoul
authored andcommitted
soundwire: cadence: use pm_runtime_resume_and_get()
Use pm_runtime_resume_and_get() to replace the pm_runtime_get_sync() and pm_runtime_put_noidle() pattern. No functional changes. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://lore.kernel.org/r/20220426235623.4253-4-yung-chuan.liao@linux.intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 443a98e commit 915bf27

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

drivers/soundwire/cadence_master.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -386,12 +386,11 @@ static int cdns_parity_error_injection(void *data, u64 value)
386386
* Resume Master device. If this results in a bus reset, the
387387
* Slave devices will re-attach and be re-enumerated.
388388
*/
389-
ret = pm_runtime_get_sync(bus->dev);
389+
ret = pm_runtime_resume_and_get(bus->dev);
390390
if (ret < 0 && ret != -EACCES) {
391391
dev_err_ratelimited(cdns->dev,
392-
"pm_runtime_get_sync failed in %s, ret %d\n",
392+
"pm_runtime_resume_and_get failed in %s, ret %d\n",
393393
__func__, ret);
394-
pm_runtime_put_noidle(bus->dev);
395394
return ret;
396395
}
397396

0 commit comments

Comments
 (0)