summaryrefslogtreecommitdiff
path: root/drivers/soundwire/intel_auxdevice.c
diff options
context:
space:
mode:
authorBard Liao <yung-chuan.liao@linux.intel.com>2024-04-10 02:34:36 +0000
committerVinod Koul <vkoul@kernel.org>2024-04-11 22:52:51 +0530
commit6f4867fa57604fc898a63ee73fe890786b9f4a72 (patch)
tree23c88725c860961c07acf3f99dcb9f4a311ee882 /drivers/soundwire/intel_auxdevice.c
parent62707b56b2b47dfdc94d4b079c9f9bfe5a923e33 (diff)
soundwire: intel_auxdevice: use pm_runtime_resume() instead of pm_request_resume()
We need to wait for each child to fully resume. pm_request_resume() is asynchronous, what we need is to wait synchronously to avoid race conditions. Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com> Link: https://lore.kernel.org/r/20240410023438.487017-3-yung-chuan.liao@linux.intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/intel_auxdevice.c')
-rw-r--r--drivers/soundwire/intel_auxdevice.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/soundwire/intel_auxdevice.c b/drivers/soundwire/intel_auxdevice.c
index 95125cc2fc59..012232cfbf7f 100644
--- a/drivers/soundwire/intel_auxdevice.c
+++ b/drivers/soundwire/intel_auxdevice.c
@@ -454,9 +454,9 @@ static int intel_resume_child_device(struct device *dev, void *data)
return 0;
}
- ret = pm_request_resume(dev);
+ ret = pm_runtime_resume(dev);
if (ret < 0) {
- dev_err(dev, "%s: pm_request_resume failed: %d\n", __func__, ret);
+ dev_err(dev, "%s: pm_runtime_resume failed: %d\n", __func__, ret);
return ret;
}
@@ -499,9 +499,9 @@ static int __maybe_unused intel_pm_prepare(struct device *dev)
* first resume the device for this link. This will also by construction
* resume the PCI parent device.
*/
- ret = pm_request_resume(dev);
+ ret = pm_runtime_resume(dev);
if (ret < 0) {
- dev_err(dev, "%s: pm_request_resume failed: %d\n", __func__, ret);
+ dev_err(dev, "%s: pm_runtime_resume failed: %d\n", __func__, ret);
return 0;
}