Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions drivers/base/power/runtime.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ static void update_pm_runtime_accounting(struct device *dev)

static void __update_runtime_status(struct device *dev, enum rpm_status status)
{
dev_info(dev, "%s status %d\n", __func__, status);
dump_stack();
update_pm_runtime_accounting(dev);
dev->power.runtime_status = status;
}
Expand Down Expand Up @@ -1307,6 +1309,9 @@ int __pm_runtime_set_status(struct device *dev, unsigned int status)
dev_err(dev, "runtime PM trying to activate child device %s but parent (%s) is not active\n",
dev_name(dev),
dev_name(parent));
dev_err(dev, " status %d, parent runtime_status %d\n",
status, parent->power.runtime_status);
dump_stack();
error = -EBUSY;
} else if (dev->power.runtime_status == RPM_SUSPENDED) {
atomic_inc(&parent->power.child_count);
Expand Down
4 changes: 4 additions & 0 deletions sound/soc/codecs/rt711.c
Original file line number Diff line number Diff line change
Expand Up @@ -1213,9 +1213,12 @@ int rt711_init(struct device *dev, struct regmap *sdw_regmap,
int rt711_io_init(struct device *dev, struct sdw_slave *slave)
{
struct rt711_priv *rt711 = dev_get_drvdata(dev);
struct device *parent = dev->parent;

rt711->disable_irq = false;

dev_info(dev, "bard: %s start hw_init %d first_hw_init %d parent %s rumtime_status %d\n",
__func__, rt711->hw_init, rt711->first_hw_init, dev_name(parent), parent->power.runtime_status);
if (rt711->hw_init)
return 0;

Expand All @@ -1228,6 +1231,7 @@ int rt711_io_init(struct device *dev, struct sdw_slave *slave)
* PM runtime is only enabled when a Slave reports as Attached
*/
if (!rt711->first_hw_init) {

/* set autosuspend parameters */
pm_runtime_set_autosuspend_delay(&slave->dev, 3000);
pm_runtime_use_autosuspend(&slave->dev);
Expand Down
2 changes: 2 additions & 0 deletions sound/soc/soc-component.c
Original file line number Diff line number Diff line change
Expand Up @@ -1234,6 +1234,8 @@ int snd_soc_pcm_component_pm_runtime_get(struct snd_soc_pcm_runtime *rtd,

for_each_rtd_components(rtd, i, component) {
int ret = pm_runtime_get_sync(component->dev);
dev_info(component->dev, "bard: %s i %d called pm_runtime_get_sync ret %d\n",
__func__, i, ret);
if (ret < 0 && ret != -EACCES) {
pm_runtime_put_noidle(component->dev);
return soc_component_ret(component, ret);
Expand Down