Linux Sound subsystem development
 help / color / mirror / Atom feed
* [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-07  8:47   ` Charles Keepax
  2025-07-23  8:42   ` (subset) " Lee Jones
  2025-07-04  7:54 ` [PATCH 60/80] soundwire: " Sakari Ailus
                   ` (8 subsequent siblings)
  9 siblings, 2 replies; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Lee Jones, James Ogletree, Fred Treven, Ben Bright, David Rhodes,
	Richard Fitzgerald
  Cc: patches, linux-kernel, linux-sound

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 drivers/mfd/arizona-irq.c  | 1 -
 drivers/mfd/cs40l50-core.c | 1 -
 drivers/mfd/cs42l43.c      | 1 -
 3 files changed, 3 deletions(-)

diff --git a/drivers/mfd/arizona-irq.c b/drivers/mfd/arizona-irq.c
index ac2139597fab..3f8622ee0e59 100644
--- a/drivers/mfd/arizona-irq.c
+++ b/drivers/mfd/arizona-irq.c
@@ -152,7 +152,6 @@ static irqreturn_t arizona_irq_thread(int irq, void *data)
 		}
 	} while (poll);
 
-	pm_runtime_mark_last_busy(arizona->dev);
 	pm_runtime_put_autosuspend(arizona->dev);
 
 	return IRQ_HANDLED;
diff --git a/drivers/mfd/cs40l50-core.c b/drivers/mfd/cs40l50-core.c
index c91bccda0858..662d987b650b 100644
--- a/drivers/mfd/cs40l50-core.c
+++ b/drivers/mfd/cs40l50-core.c
@@ -531,7 +531,6 @@ int cs40l50_probe(struct cs40l50 *cs40l50)
 	if (ret)
 		return dev_err_probe(dev, ret, "Failed to request %s\n", CS40L50_FW);
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return 0;
diff --git a/drivers/mfd/cs42l43.c b/drivers/mfd/cs42l43.c
index 103787f37443..07c8f1b8183e 100644
--- a/drivers/mfd/cs42l43.c
+++ b/drivers/mfd/cs42l43.c
@@ -962,7 +962,6 @@ static void cs42l43_boot_work(struct work_struct *work)
 		goto err;
 	}
 
-	pm_runtime_mark_last_busy(cs42l43->dev);
 	pm_runtime_put_autosuspend(cs42l43->dev);
 
 	return;
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 59/80] slimbus: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
  2025-07-04  7:54 ` [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls Sakari Ailus
  2025-07-04  7:54 ` [PATCH 60/80] soundwire: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-09  6:41   ` Srinivas Kandagatla
  2025-07-04  7:54 ` [PATCH 69/80] ALSA: hda: " Sakari Ailus
                   ` (6 subsequent siblings)
  9 siblings, 1 reply; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Srinivas Kandagatla; +Cc: linux-sound, linux-kernel, linux-arm-msm

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 drivers/slimbus/core.c      | 1 -
 drivers/slimbus/messaging.c | 2 --
 drivers/slimbus/qcom-ctrl.c | 1 -
 3 files changed, 4 deletions(-)

diff --git a/drivers/slimbus/core.c b/drivers/slimbus/core.c
index 005fa2ef100f..31751ee4e400 100644
--- a/drivers/slimbus/core.c
+++ b/drivers/slimbus/core.c
@@ -504,7 +504,6 @@ int slim_device_report_present(struct slim_controller *ctrl,
 	ret = slim_device_alloc_laddr(sbdev, true);
 
 slimbus_not_active:
-	pm_runtime_mark_last_busy(ctrl->dev);
 	pm_runtime_put_autosuspend(ctrl->dev);
 	return ret;
 }
diff --git a/drivers/slimbus/messaging.c b/drivers/slimbus/messaging.c
index 6f01d944f9c6..44197493010e 100644
--- a/drivers/slimbus/messaging.c
+++ b/drivers/slimbus/messaging.c
@@ -47,7 +47,6 @@ void slim_msg_response(struct slim_controller *ctrl, u8 *reply, u8 tid, u8 len)
 		complete(txn->comp);
 
 	/* Remove runtime-pm vote now that response was received for TID txn */
-	pm_runtime_mark_last_busy(ctrl->dev);
 	pm_runtime_put_autosuspend(ctrl->dev);
 }
 EXPORT_SYMBOL_GPL(slim_msg_response);
@@ -171,7 +170,6 @@ int slim_do_transfer(struct slim_controller *ctrl, struct slim_msg_txn *txn)
 		 * remove runtime-pm vote if this was TX only, or
 		 * if there was error during this transaction
 		 */
-		pm_runtime_mark_last_busy(ctrl->dev);
 		pm_runtime_put_autosuspend(ctrl->dev);
 	}
 	return ret;
diff --git a/drivers/slimbus/qcom-ctrl.c b/drivers/slimbus/qcom-ctrl.c
index ab344f7472f2..880cf3081a20 100644
--- a/drivers/slimbus/qcom-ctrl.c
+++ b/drivers/slimbus/qcom-ctrl.c
@@ -695,7 +695,6 @@ static int qcom_slim_resume(struct device *dev)
 		dev_dbg(dev, "system resume");
 		ret = qcom_slim_runtime_resume(dev);
 		if (!ret) {
-			pm_runtime_mark_last_busy(dev);
 			pm_request_autosuspend(dev);
 		}
 		return ret;
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 60/80] soundwire: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
  2025-07-04  7:54 ` [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04  7:54 ` [PATCH 59/80] slimbus: " Sakari Ailus
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Vinod Koul, Bard Liao, Pierre-Louis Bossart, Srinivas Kandagatla
  Cc: linux-sound, linux-kernel, linux-arm-msm

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 drivers/soundwire/bus.c            | 1 -
 drivers/soundwire/cadence_master.c | 1 -
 drivers/soundwire/qcom.c           | 3 ---
 3 files changed, 5 deletions(-)

diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c
index 4fd5cac799c5..0d31bb2aff24 100644
--- a/drivers/soundwire/bus.c
+++ b/drivers/soundwire/bus.c
@@ -1833,7 +1833,6 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave)
 		dev_warn(&slave->dev, "Reached MAX_RETRY on alert read\n");
 
 io_err:
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	return ret;
diff --git a/drivers/soundwire/cadence_master.c b/drivers/soundwire/cadence_master.c
index 21bb491d026b..bdd538d09ee7 100644
--- a/drivers/soundwire/cadence_master.c
+++ b/drivers/soundwire/cadence_master.c
@@ -486,7 +486,6 @@ static int cdns_parity_error_injection(void *data, u64 value)
 	 * allow Master device to enter pm_runtime suspend. This may
 	 * also result in Slave devices suspending.
 	 */
-	pm_runtime_mark_last_busy(bus->dev);
 	pm_runtime_put_autosuspend(bus->dev);
 
 	return 0;
diff --git a/drivers/soundwire/qcom.c b/drivers/soundwire/qcom.c
index 3265c39e6b51..0ab7e2c7945f 100644
--- a/drivers/soundwire/qcom.c
+++ b/drivers/soundwire/qcom.c
@@ -657,7 +657,6 @@ static irqreturn_t qcom_swrm_wake_irq_handler(int irq, void *dev_id)
 			disable_irq_nosync(ctrl->wake_irq);
 	}
 
-	pm_runtime_mark_last_busy(ctrl->dev);
 	pm_runtime_put_autosuspend(ctrl->dev);
 
 	return IRQ_HANDLED;
@@ -1319,7 +1318,6 @@ static void qcom_swrm_shutdown(struct snd_pcm_substream *substream,
 	struct qcom_swrm_ctrl *ctrl = dev_get_drvdata(dai->dev);
 
 	swrm_wait_for_wr_fifo_done(ctrl);
-	pm_runtime_mark_last_busy(ctrl->dev);
 	pm_runtime_put_autosuspend(ctrl->dev);
 
 }
@@ -1502,7 +1500,6 @@ static int swrm_reg_show(struct seq_file *s_file, void *data)
 		ctrl->reg_read(ctrl, reg, &reg_val);
 		seq_printf(s_file, "0x%.3x: 0x%.2x\n", reg, reg_val);
 	}
-	pm_runtime_mark_last_busy(ctrl->dev);
 	pm_runtime_put_autosuspend(ctrl->dev);
 
 
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 70/80] ASoC: atmel: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (3 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 69/80] ALSA: hda: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04  7:54 ` [PATCH 71/80] ASoC: codecs: " Sakari Ailus
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Claudiu Beznea, Andrei Simion, Liam Girdwood, Mark Brown,
	Jaroslav Kysela, Takashi Iwai, Nicolas Ferre, Alexandre Belloni
  Cc: linux-sound, linux-arm-kernel, linux-kernel

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/soc/atmel/mchp-spdifrx.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/sound/soc/atmel/mchp-spdifrx.c b/sound/soc/atmel/mchp-spdifrx.c
index fb820609c043..521bee4998f8 100644
--- a/sound/soc/atmel/mchp-spdifrx.c
+++ b/sound/soc/atmel/mchp-spdifrx.c
@@ -577,7 +577,6 @@ static int mchp_spdifrx_cs_get(struct mchp_spdifrx_dev *dev,
 	       sizeof(ch_stat->data));
 
 pm_runtime_put:
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 unlock:
 	mutex_unlock(&dev->mlock);
@@ -660,7 +659,6 @@ static int mchp_spdifrx_subcode_ch_get(struct mchp_spdifrx_dev *dev,
 	       sizeof(user_data->data));
 
 pm_runtime_put:
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 unlock:
 	mutex_unlock(&dev->mlock);
@@ -726,7 +724,6 @@ static int mchp_spdifrx_ulock_get(struct snd_kcontrol *kcontrol,
 
 	uvalue->value.integer.value[0] = ctrl->ulock;
 
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 unlock:
 	mutex_unlock(&dev->mlock);
@@ -762,7 +759,6 @@ static int mchp_spdifrx_badf_get(struct snd_kcontrol *kcontrol,
 		ctrl->badf = 0;
 	}
 
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 unlock:
 	mutex_unlock(&dev->mlock);
@@ -811,7 +807,6 @@ static int mchp_spdifrx_signal_get(struct snd_kcontrol *kcontrol,
 		regmap_read(dev->regmap, SPDIFRX_RSR, &val);
 	}
 
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 
 unlock:
@@ -875,7 +870,6 @@ static int mchp_spdifrx_rate_get(struct snd_kcontrol *kcontrol,
 	ucontrol->value.integer.value[0] = rate / (32 * SPDIFRX_RSR_IFS(val));
 
 pm_runtime_put:
-	pm_runtime_mark_last_busy(dev->dev);
 	pm_runtime_put_autosuspend(dev->dev);
 unlock:
 	mutex_unlock(&dev->mlock);
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 69/80] ALSA: hda: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (2 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 59/80] slimbus: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04 11:47   ` Takashi Iwai
  2025-07-04  7:54 ` [PATCH 70/80] ASoC: atmel: " Sakari Ailus
                   ` (5 subsequent siblings)
  9 siblings, 1 reply; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Jaroslav Kysela, Takashi Iwai, David Rhodes, Richard Fitzgerald,
	Shenghao Ding, Kevin Lu, Baojun Xu, Amadeusz Sławiński,
	Sakari Ailus, Cezary Rojewski, Mark Brown, Andy Shevchenko,
	Dan Carpenter, Chen Ni
  Cc: linux-sound, linux-kernel, patches

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/hda/hdac_device.c         | 1 -
 sound/pci/hda/cs35l41_hda.c     | 4 ----
 sound/pci/hda/cs35l56_hda.c     | 1 -
 sound/pci/hda/tas2781_hda_i2c.c | 3 ---
 sound/pci/hda/tas2781_hda_spi.c | 4 ----
 5 files changed, 13 deletions(-)

diff --git a/sound/hda/hdac_device.c b/sound/hda/hdac_device.c
index 0053831eed2d..a02dce5f6a88 100644
--- a/sound/hda/hdac_device.c
+++ b/sound/hda/hdac_device.c
@@ -581,7 +581,6 @@ int snd_hdac_power_down(struct hdac_device *codec)
 {
 	struct device *dev = &codec->dev;
 
-	pm_runtime_mark_last_busy(dev);
 	return pm_runtime_put_autosuspend(dev);
 }
 EXPORT_SYMBOL_GPL(snd_hdac_power_down);
diff --git a/sound/pci/hda/cs35l41_hda.c b/sound/pci/hda/cs35l41_hda.c
index c2cf3813872a..fc3f9ed3be13 100644
--- a/sound/pci/hda/cs35l41_hda.c
+++ b/sound/pci/hda/cs35l41_hda.c
@@ -836,7 +836,6 @@ static void cs35l41_hda_playback_hook(struct device *dev, int action)
 		 * Playback must be finished for all amps before we start runtime suspend.
 		 * This ensures no amps are playing back when we start putting them to sleep.
 		 */
-		pm_runtime_mark_last_busy(dev);
 		pm_runtime_put_autosuspend(dev);
 		break;
 	default:
@@ -1284,7 +1283,6 @@ static void cs35l41_fw_load_work(struct work_struct *work)
 	cs35l41->fw_request_ongoing = false;
 	mutex_unlock(&cs35l41->fw_mutex);
 
-	pm_runtime_mark_last_busy(cs35l41->dev);
 	pm_runtime_put_autosuspend(cs35l41->dev);
 }
 
@@ -1515,7 +1513,6 @@ static int cs35l41_hda_bind(struct device *dev, struct device *master, void *mas
 		dev_warn(dev, "Unable to create device link\n");
 	unlock_system_sleep(sleep_flags);
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	dev_info(cs35l41->dev,
@@ -2036,7 +2033,6 @@ int cs35l41_hda_probe(struct device *dev, const char *device_name, int id, int i
 
 	pm_runtime_set_autosuspend_delay(cs35l41->dev, 3000);
 	pm_runtime_use_autosuspend(cs35l41->dev);
-	pm_runtime_mark_last_busy(cs35l41->dev);
 	pm_runtime_set_active(cs35l41->dev);
 	pm_runtime_get_noresume(cs35l41->dev);
 	pm_runtime_enable(cs35l41->dev);
diff --git a/sound/pci/hda/cs35l56_hda.c b/sound/pci/hda/cs35l56_hda.c
index 3f2fd32f4ad9..0391bbffed7d 100644
--- a/sound/pci/hda/cs35l56_hda.c
+++ b/sound/pci/hda/cs35l56_hda.c
@@ -89,7 +89,6 @@ static void cs35l56_hda_pause(struct cs35l56_hda *cs35l56)
 			  BIT(CS35L56_ASP_TX1_EN_SHIFT) | BIT(CS35L56_ASP_TX2_EN_SHIFT) |
 			  BIT(CS35L56_ASP_TX3_EN_SHIFT) | BIT(CS35L56_ASP_TX4_EN_SHIFT));
 
-	pm_runtime_mark_last_busy(cs35l56->base.dev);
 	pm_runtime_put_autosuspend(cs35l56->base.dev);
 }
 
diff --git a/sound/pci/hda/tas2781_hda_i2c.c b/sound/pci/hda/tas2781_hda_i2c.c
index b9cdbca951e4..8a461acbc3b9 100644
--- a/sound/pci/hda/tas2781_hda_i2c.c
+++ b/sound/pci/hda/tas2781_hda_i2c.c
@@ -157,7 +157,6 @@ static void tas2781_hda_playback_hook(struct device *dev, int action)
 		tas_hda->priv->playback_started = false;
 		mutex_unlock(&tas_hda->priv->codec_lock);
 
-		pm_runtime_mark_last_busy(dev);
 		pm_runtime_put_autosuspend(dev);
 		break;
 	default:
@@ -483,7 +482,6 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
 out:
 	mutex_unlock(&tas_hda->priv->codec_lock);
 	release_firmware(fmw);
-	pm_runtime_mark_last_busy(tas_hda->dev);
 	pm_runtime_put_autosuspend(tas_hda->dev);
 }
 
@@ -526,7 +524,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
 	if (!ret)
 		comp->playback_hook = tas2781_hda_playback_hook;
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return ret;
diff --git a/sound/pci/hda/tas2781_hda_spi.c b/sound/pci/hda/tas2781_hda_spi.c
index 5c03e9d2283a..c4b9a3c1a7f0 100644
--- a/sound/pci/hda/tas2781_hda_spi.c
+++ b/sound/pci/hda/tas2781_hda_spi.c
@@ -400,7 +400,6 @@ static void tas2781_hda_playback_hook(struct device *dev, int action)
 		guard(mutex)(&tas_priv->codec_lock);
 		if (tas_priv->fw_state == TASDEVICE_DSP_FW_ALL_OK)
 			tasdevice_tuning_switch(tas_priv, 1);
-		pm_runtime_mark_last_busy(dev);
 		pm_runtime_put_autosuspend(dev);
 	}
 }
@@ -698,7 +697,6 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
 	tas2781_save_calibration(tas_hda);
 out:
 	release_firmware(fmw);
-	pm_runtime_mark_last_busy(tas_hda->priv->dev);
 	pm_runtime_put_autosuspend(tas_hda->priv->dev);
 }
 
@@ -731,7 +729,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
 	if (!ret)
 		comp->playback_hook = tas2781_hda_playback_hook;
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return ret;
@@ -816,7 +813,6 @@ static int tas2781_hda_spi_probe(struct spi_device *spi)
 
 	pm_runtime_set_autosuspend_delay(tas_priv->dev, 3000);
 	pm_runtime_use_autosuspend(tas_priv->dev);
-	pm_runtime_mark_last_busy(tas_priv->dev);
 	pm_runtime_set_active(tas_priv->dev);
 	pm_runtime_get_noresume(tas_priv->dev);
 	pm_runtime_enable(tas_priv->dev);
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 71/80] ASoC: codecs: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (4 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 70/80] ASoC: atmel: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-07  9:16   ` Charles Keepax
  2025-07-04  7:54 ` [PATCH 72/80] ASoC: Intel: " Sakari Ailus
                   ` (3 subsequent siblings)
  9 siblings, 1 reply; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	David Rhodes, Richard Fitzgerald, Oder Chiou, Shenghao Ding,
	Kevin Lu, Baojun Xu, Srinivas Kandagatla, Sakari Ailus,
	Cezary Rojewski, Amadeusz Sławiński, Charles Keepax,
	Krzysztof Kozlowski
  Cc: patches, linux-sound, linux-kernel, linux-arm-msm

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/soc/codecs/arizona-jack.c    | 2 --
 sound/soc/codecs/cs35l41.c         | 2 --
 sound/soc/codecs/cs35l45.c         | 1 -
 sound/soc/codecs/cs35l56-sdw.c     | 1 -
 sound/soc/codecs/cs35l56.c         | 1 -
 sound/soc/codecs/cs42l42.c         | 1 -
 sound/soc/codecs/cs42l43-jack.c    | 5 -----
 sound/soc/codecs/cs42l43.c         | 2 --
 sound/soc/codecs/cs48l32.c         | 1 -
 sound/soc/codecs/hda.c             | 3 ---
 sound/soc/codecs/max98363.c        | 1 -
 sound/soc/codecs/max98373-sdw.c    | 1 -
 sound/soc/codecs/rt1017-sdca-sdw.c | 1 -
 sound/soc/codecs/rt1308-sdw.c      | 1 -
 sound/soc/codecs/rt1316-sdw.c      | 1 -
 sound/soc/codecs/rt1318-sdw.c      | 1 -
 sound/soc/codecs/rt1320-sdw.c      | 1 -
 sound/soc/codecs/rt5682-sdw.c      | 1 -
 sound/soc/codecs/rt700.c           | 2 --
 sound/soc/codecs/rt711-sdca.c      | 2 --
 sound/soc/codecs/rt711.c           | 2 --
 sound/soc/codecs/rt712-sdca-dmic.c | 1 -
 sound/soc/codecs/rt712-sdca.c      | 2 --
 sound/soc/codecs/rt715-sdca.c      | 1 -
 sound/soc/codecs/rt715.c           | 1 -
 sound/soc/codecs/rt721-sdca.c      | 2 --
 sound/soc/codecs/rt722-sdca.c      | 2 --
 sound/soc/codecs/rt9123.c          | 3 ---
 sound/soc/codecs/tas2552.c         | 1 -
 sound/soc/codecs/wcd-mbhc-v2.c     | 2 --
 sound/soc/codecs/wsa881x.c         | 1 -
 sound/soc/codecs/wsa883x.c         | 1 -
 sound/soc/codecs/wsa884x.c         | 1 -
 33 files changed, 51 deletions(-)

diff --git a/sound/soc/codecs/arizona-jack.c b/sound/soc/codecs/arizona-jack.c
index 9c15ddba6008..22f9c431a0e5 100644
--- a/sound/soc/codecs/arizona-jack.c
+++ b/sound/soc/codecs/arizona-jack.c
@@ -319,7 +319,6 @@ static void arizona_stop_mic(struct arizona_priv *info)
 
 	if (change) {
 		regulator_disable(info->micvdd);
-		pm_runtime_mark_last_busy(arizona->dev);
 		pm_runtime_put_autosuspend(arizona->dev);
 	}
 }
@@ -1127,7 +1126,6 @@ static irqreturn_t arizona_jackdet(int irq, void *data)
 
 	mutex_unlock(&info->lock);
 
-	pm_runtime_mark_last_busy(arizona->dev);
 	pm_runtime_put_autosuspend(arizona->dev);
 
 	return IRQ_HANDLED;
diff --git a/sound/soc/codecs/cs35l41.c b/sound/soc/codecs/cs35l41.c
index ff4134bee858..224d65987a8d 100644
--- a/sound/soc/codecs/cs35l41.c
+++ b/sound/soc/codecs/cs35l41.c
@@ -483,7 +483,6 @@ static irqreturn_t cs35l41_irq(int irq, void *data)
 	}
 
 done:
-	pm_runtime_mark_last_busy(cs35l41->dev);
 	pm_runtime_put_autosuspend(cs35l41->dev);
 
 	return ret;
@@ -1328,7 +1327,6 @@ int cs35l41_probe(struct cs35l41_private *cs35l41, const struct cs35l41_hw_cfg *
 
 	pm_runtime_set_autosuspend_delay(cs35l41->dev, 3000);
 	pm_runtime_use_autosuspend(cs35l41->dev);
-	pm_runtime_mark_last_busy(cs35l41->dev);
 	pm_runtime_set_active(cs35l41->dev);
 	pm_runtime_get_noresume(cs35l41->dev);
 	pm_runtime_enable(cs35l41->dev);
diff --git a/sound/soc/codecs/cs35l45.c b/sound/soc/codecs/cs35l45.c
index 432a19f4de2b..d4dcdf37bb70 100644
--- a/sound/soc/codecs/cs35l45.c
+++ b/sound/soc/codecs/cs35l45.c
@@ -1427,7 +1427,6 @@ int cs35l45_probe(struct cs35l45_private *cs35l45)
 
 	pm_runtime_set_autosuspend_delay(cs35l45->dev, 3000);
 	pm_runtime_use_autosuspend(cs35l45->dev);
-	pm_runtime_mark_last_busy(cs35l45->dev);
 	pm_runtime_set_active(cs35l45->dev);
 	pm_runtime_get_noresume(cs35l45->dev);
 	pm_runtime_enable(cs35l45->dev);
diff --git a/sound/soc/codecs/cs35l56-sdw.c b/sound/soc/codecs/cs35l56-sdw.c
index fa9693af3722..ee14031695a1 100644
--- a/sound/soc/codecs/cs35l56-sdw.c
+++ b/sound/soc/codecs/cs35l56-sdw.c
@@ -283,7 +283,6 @@ static void cs35l56_sdw_init(struct sdw_slave *peripheral)
 	}
 
 out:
-	pm_runtime_mark_last_busy(cs35l56->base.dev);
 	pm_runtime_put_autosuspend(cs35l56->base.dev);
 }
 
diff --git a/sound/soc/codecs/cs35l56.c b/sound/soc/codecs/cs35l56.c
index 1b42586794ad..b1c65d8331e7 100644
--- a/sound/soc/codecs/cs35l56.c
+++ b/sound/soc/codecs/cs35l56.c
@@ -871,7 +871,6 @@ static void cs35l56_dsp_work(struct work_struct *work)
 
 	cs35l56_log_tuning(&cs35l56->base, &cs35l56->dsp.cs_dsp);
 err:
-	pm_runtime_mark_last_busy(cs35l56->base.dev);
 	pm_runtime_put_autosuspend(cs35l56->base.dev);
 }
 
diff --git a/sound/soc/codecs/cs42l42.c b/sound/soc/codecs/cs42l42.c
index 56668c392063..78bb093fa0cc 100644
--- a/sound/soc/codecs/cs42l42.c
+++ b/sound/soc/codecs/cs42l42.c
@@ -1775,7 +1775,6 @@ irqreturn_t cs42l42_irq_thread(int irq, void *data)
 	}
 
 	mutex_unlock(&cs42l42->irq_lock);
-	pm_runtime_mark_last_busy(cs42l42->dev);
 	pm_runtime_put_autosuspend(cs42l42->dev);
 
 	return IRQ_HANDLED;
diff --git a/sound/soc/codecs/cs42l43-jack.c b/sound/soc/codecs/cs42l43-jack.c
index 72a4150709de..2a0a4986a9ce 100644
--- a/sound/soc/codecs/cs42l43-jack.c
+++ b/sound/soc/codecs/cs42l43-jack.c
@@ -242,7 +242,6 @@ int cs42l43_set_jack(struct snd_soc_component *component,
 error:
 	mutex_unlock(&priv->jack_lock);
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 
 	return ret;
@@ -429,7 +428,6 @@ irqreturn_t cs42l43_button_press(int irq, void *data)
 error:
 	mutex_unlock(&priv->jack_lock);
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 
 	return iret;
@@ -461,7 +459,6 @@ irqreturn_t cs42l43_button_release(int irq, void *data)
 
 	mutex_unlock(&priv->jack_lock);
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 
 	return iret;
@@ -496,7 +493,6 @@ void cs42l43_bias_sense_timeout(struct work_struct *work)
 
 	mutex_unlock(&priv->jack_lock);
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 }
 
@@ -768,7 +764,6 @@ void cs42l43_tip_sense_work(struct work_struct *work)
 
 	priv->suspend_jack_debounce = false;
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 }
 
diff --git a/sound/soc/codecs/cs42l43.c b/sound/soc/codecs/cs42l43.c
index 41a0f4529ea1..b0c27d696c58 100644
--- a/sound/soc/codecs/cs42l43.c
+++ b/sound/soc/codecs/cs42l43.c
@@ -1080,7 +1080,6 @@ static int cs42l43_shutter_get(struct cs42l43_codec *priv, unsigned int shift)
 		ret ? "open" : "closed");
 
 error:
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 
 	return ret;
@@ -2356,7 +2355,6 @@ static int cs42l43_codec_probe(struct platform_device *pdev)
 		goto err_clk;
 	}
 
-	pm_runtime_mark_last_busy(priv->dev);
 	pm_runtime_put_autosuspend(priv->dev);
 
 	return 0;
diff --git a/sound/soc/codecs/cs48l32.c b/sound/soc/codecs/cs48l32.c
index 9bdd48aab42a..a306af4289ad 100644
--- a/sound/soc/codecs/cs48l32.c
+++ b/sound/soc/codecs/cs48l32.c
@@ -1385,7 +1385,6 @@ static irqreturn_t cs48l32_irq(int irq, void *data)
 	result = IRQ_HANDLED;
 
 out:
-	pm_runtime_mark_last_busy(cs48l32_codec->core.dev);
 	pm_runtime_put_autosuspend(cs48l32_codec->core.dev);
 
 	return result;
diff --git a/sound/soc/codecs/hda.c b/sound/soc/codecs/hda.c
index dc7794c9ac44..7e4df1481486 100644
--- a/sound/soc/codecs/hda.c
+++ b/sound/soc/codecs/hda.c
@@ -162,7 +162,6 @@ int hda_codec_probe_complete(struct hda_codec *codec)
 	snd_hda_codec_register(codec);
 
 	/* Complement pm_runtime_get_sync(bus) in probe */
-	pm_runtime_mark_last_busy(bus->dev);
 	pm_runtime_put_autosuspend(bus->dev);
 
 	return ret;
@@ -262,7 +261,6 @@ static int hda_codec_probe(struct snd_soc_component *component)
 
 	snd_hdac_ext_bus_link_put(bus, hlink);
 
-	pm_runtime_mark_last_busy(bus->dev);
 	pm_runtime_put_autosuspend(bus->dev);
 	return ret;
 }
@@ -300,7 +298,6 @@ static void hda_codec_remove(struct snd_soc_component *component)
 	 * not be called due to early error, leaving bus uc unbalanced
 	 */
 	if (!was_registered) {
-		pm_runtime_mark_last_busy(bus->dev);
 		pm_runtime_put_autosuspend(bus->dev);
 	}
 
diff --git a/sound/soc/codecs/max98363.c b/sound/soc/codecs/max98363.c
index fd6830a7579d..25af78ab30d5 100644
--- a/sound/soc/codecs/max98363.c
+++ b/sound/soc/codecs/max98363.c
@@ -188,7 +188,6 @@ static int max98363_io_init(struct sdw_slave *slave)
 	max98363->hw_init = true;
 
 out:
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return ret;
diff --git a/sound/soc/codecs/max98373-sdw.c b/sound/soc/codecs/max98373-sdw.c
index 43b52bda6ad5..88ff215f52b3 100644
--- a/sound/soc/codecs/max98373-sdw.c
+++ b/sound/soc/codecs/max98373-sdw.c
@@ -458,7 +458,6 @@ static int max98373_io_init(struct sdw_slave *slave)
 	max98373->first_hw_init = true;
 	max98373->hw_init = true;
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return 0;
diff --git a/sound/soc/codecs/rt1017-sdca-sdw.c b/sound/soc/codecs/rt1017-sdca-sdw.c
index 88fc23a4999f..a9c000876be8 100644
--- a/sound/soc/codecs/rt1017-sdca-sdw.c
+++ b/sound/soc/codecs/rt1017-sdca-sdw.c
@@ -362,7 +362,6 @@ static int rt1017_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt1017->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "hw_init complete\n");
diff --git a/sound/soc/codecs/rt1308-sdw.c b/sound/soc/codecs/rt1308-sdw.c
index ea708068f0e8..b6c224832a43 100644
--- a/sound/soc/codecs/rt1308-sdw.c
+++ b/sound/soc/codecs/rt1308-sdw.c
@@ -291,7 +291,6 @@ static int rt1308_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt1308->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt1316-sdw.c b/sound/soc/codecs/rt1316-sdw.c
index 960b6c4f5a66..01a977398864 100644
--- a/sound/soc/codecs/rt1316-sdw.c
+++ b/sound/soc/codecs/rt1316-sdw.c
@@ -302,7 +302,6 @@ static int rt1316_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt1316->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt1318-sdw.c b/sound/soc/codecs/rt1318-sdw.c
index 4eb636e0c9ed..70db5450d6d2 100644
--- a/sound/soc/codecs/rt1318-sdw.c
+++ b/sound/soc/codecs/rt1318-sdw.c
@@ -434,7 +434,6 @@ static int rt1318_io_init(struct device *dev, struct sdw_slave *slave)
 	rt1318->first_hw_init = true;
 	rt1318->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt1320-sdw.c b/sound/soc/codecs/rt1320-sdw.c
index 015cc710e6dc..b13d7a99bf63 100644
--- a/sound/soc/codecs/rt1320-sdw.c
+++ b/sound/soc/codecs/rt1320-sdw.c
@@ -763,7 +763,6 @@ static int rt1320_io_init(struct device *dev, struct sdw_slave *slave)
 	rt1320->first_hw_init = true;
 	rt1320->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt5682-sdw.c b/sound/soc/codecs/rt5682-sdw.c
index aa229894129b..055bea0a4a3b 100644
--- a/sound/soc/codecs/rt5682-sdw.c
+++ b/sound/soc/codecs/rt5682-sdw.c
@@ -474,7 +474,6 @@ static int rt5682_io_init(struct device *dev, struct sdw_slave *slave)
 	rt5682->first_hw_init = true;
 
 err_nodev:
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete: %d\n", __func__, ret);
diff --git a/sound/soc/codecs/rt700.c b/sound/soc/codecs/rt700.c
index 434b926f96c8..8f6d569c8f25 100644
--- a/sound/soc/codecs/rt700.c
+++ b/sound/soc/codecs/rt700.c
@@ -338,7 +338,6 @@ static int rt700_set_jack_detect(struct snd_soc_component *component,
 
 	rt700_jack_init(rt700);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1230,7 +1229,6 @@ int rt700_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt700->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt711-sdca.c b/sound/soc/codecs/rt711-sdca.c
index dd6ccf17afd4..16c351779243 100644
--- a/sound/soc/codecs/rt711-sdca.c
+++ b/sound/soc/codecs/rt711-sdca.c
@@ -545,7 +545,6 @@ static int rt711_sdca_set_jack_detect(struct snd_soc_component *component,
 
 	rt711_sdca_jack_init(rt711);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1662,7 +1661,6 @@ int rt711_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt711->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt711.c b/sound/soc/codecs/rt711.c
index 5446f9506a16..af3a49aee618 100644
--- a/sound/soc/codecs/rt711.c
+++ b/sound/soc/codecs/rt711.c
@@ -480,7 +480,6 @@ static int rt711_set_jack_detect(struct snd_soc_component *component,
 
 	rt711_jack_init(rt711);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1331,7 +1330,6 @@ int rt711_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt711->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt712-sdca-dmic.c b/sound/soc/codecs/rt712-sdca-dmic.c
index 4d044dfa3136..42f8f7b8bed0 100644
--- a/sound/soc/codecs/rt712-sdca-dmic.c
+++ b/sound/soc/codecs/rt712-sdca-dmic.c
@@ -236,7 +236,6 @@ static int rt712_sdca_dmic_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt712->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt712-sdca.c b/sound/soc/codecs/rt712-sdca.c
index 570c2af1245d..5b298db5f0f6 100644
--- a/sound/soc/codecs/rt712-sdca.c
+++ b/sound/soc/codecs/rt712-sdca.c
@@ -479,7 +479,6 @@ static int rt712_sdca_set_jack_detect(struct snd_soc_component *component,
 
 	rt712_sdca_jack_init(rt712);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1925,7 +1924,6 @@ int rt712_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
 
 suspend:
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	return 0;
diff --git a/sound/soc/codecs/rt715-sdca.c b/sound/soc/codecs/rt715-sdca.c
index 7fb02654c16b..db7d43349d7d 100644
--- a/sound/soc/codecs/rt715-sdca.c
+++ b/sound/soc/codecs/rt715-sdca.c
@@ -1065,7 +1065,6 @@ int rt715_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt715->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	return 0;
diff --git a/sound/soc/codecs/rt715.c b/sound/soc/codecs/rt715.c
index 2cf461852091..0fa445d88e23 100644
--- a/sound/soc/codecs/rt715.c
+++ b/sound/soc/codecs/rt715.c
@@ -1129,7 +1129,6 @@ int rt715_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt715->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	return 0;
diff --git a/sound/soc/codecs/rt721-sdca.c b/sound/soc/codecs/rt721-sdca.c
index ba080957e933..f6f7c2ffde1c 100644
--- a/sound/soc/codecs/rt721-sdca.c
+++ b/sound/soc/codecs/rt721-sdca.c
@@ -327,7 +327,6 @@ static int rt721_sdca_set_jack_detect(struct snd_soc_component *component,
 
 	rt721_sdca_jack_init(rt721);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1548,7 +1547,6 @@ int rt721_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt721->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt722-sdca.c b/sound/soc/codecs/rt722-sdca.c
index ac9588284a95..333611490ae3 100644
--- a/sound/soc/codecs/rt722-sdca.c
+++ b/sound/soc/codecs/rt722-sdca.c
@@ -339,7 +339,6 @@ static int rt722_sdca_set_jack_detect(struct snd_soc_component *component,
 
 	rt722_sdca_jack_init(rt722);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1559,7 +1558,6 @@ int rt722_sdca_io_init(struct device *dev, struct sdw_slave *slave)
 	/* Mark Slave initialization complete */
 	rt722->hw_init = true;
 
-	pm_runtime_mark_last_busy(&slave->dev);
 	pm_runtime_put_autosuspend(&slave->dev);
 
 	dev_dbg(&slave->dev, "%s hw_init complete\n", __func__);
diff --git a/sound/soc/codecs/rt9123.c b/sound/soc/codecs/rt9123.c
index 242e8c975a62..b162824526d6 100644
--- a/sound/soc/codecs/rt9123.c
+++ b/sound/soc/codecs/rt9123.c
@@ -77,7 +77,6 @@ static int rt9123_enable_event(struct snd_soc_dapm_widget *w, struct snd_kcontro
 	/* AMPON bit is located in volatile RG, use pm_runtime to guarantee the RG access */
 	snd_soc_component_write_field(comp, RT9123_REG_AMPCTRL, RT9123_MASK_AMPON, enable);
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 
 	return 0;
@@ -140,7 +139,6 @@ static int rt9123_xhandler_get(struct snd_kcontrol *kcontrol, struct snd_ctl_ele
 	if (ret < 0)
 		dev_err(dev, "Failed to get control (%d)\n", ret);
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 	return ret;
 }
@@ -168,7 +166,6 @@ static int rt9123_xhandler_put(struct snd_kcontrol *kcontrol, struct snd_ctl_ele
 	if (ret < 0)
 		dev_err(dev, "Failed to put control (%d)\n", ret);
 
-	pm_runtime_mark_last_busy(dev);
 	pm_runtime_put_autosuspend(dev);
 	return ret;
 }
diff --git a/sound/soc/codecs/tas2552.c b/sound/soc/codecs/tas2552.c
index b56dd279d90a..43449d7c2584 100644
--- a/sound/soc/codecs/tas2552.c
+++ b/sound/soc/codecs/tas2552.c
@@ -724,7 +724,6 @@ static int tas2552_probe(struct i2c_client *client)
 	pm_runtime_set_autosuspend_delay(&client->dev, 1000);
 	pm_runtime_use_autosuspend(&client->dev);
 	pm_runtime_enable(&client->dev);
-	pm_runtime_mark_last_busy(&client->dev);
 	pm_runtime_put_sync_autosuspend(&client->dev);
 
 	dev_set_drvdata(&client->dev, data);
diff --git a/sound/soc/codecs/wcd-mbhc-v2.c b/sound/soc/codecs/wcd-mbhc-v2.c
index 4b7c3d6080a1..26ebcdadeb7d 100644
--- a/sound/soc/codecs/wcd-mbhc-v2.c
+++ b/sound/soc/codecs/wcd-mbhc-v2.c
@@ -825,7 +825,6 @@ static int wcd_mbhc_initialise(struct wcd_mbhc *mbhc)
 
 	mutex_unlock(&mbhc->lock);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return 0;
@@ -1319,7 +1318,6 @@ static void wcd_correct_swch_plug(struct work_struct *work)
 	if (mbhc->mbhc_cb->hph_pull_down_ctrl)
 		mbhc->mbhc_cb->hph_pull_down_ctrl(component, true);
 
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 }
 
diff --git a/sound/soc/codecs/wsa881x.c b/sound/soc/codecs/wsa881x.c
index d479521a6d50..636e59abc377 100644
--- a/sound/soc/codecs/wsa881x.c
+++ b/sound/soc/codecs/wsa881x.c
@@ -775,7 +775,6 @@ static int wsa881x_put_pa_gain(struct snd_kcontrol *kc,
 		usleep_range(1000, 1010);
 	}
 
-	pm_runtime_mark_last_busy(comp->dev);
 	pm_runtime_put_autosuspend(comp->dev);
 
 	return 1;
diff --git a/sound/soc/codecs/wsa883x.c b/sound/soc/codecs/wsa883x.c
index 13c9d4a6f015..188363b03b93 100644
--- a/sound/soc/codecs/wsa883x.c
+++ b/sound/soc/codecs/wsa883x.c
@@ -1491,7 +1491,6 @@ static int wsa883x_get_temp(struct wsa883x_priv *wsa883x, long *temp)
 		ret = -EAGAIN;
 	}
 out:
-	pm_runtime_mark_last_busy(wsa883x->dev);
 	pm_runtime_put_autosuspend(wsa883x->dev);
 
 	return ret;
diff --git a/sound/soc/codecs/wsa884x.c b/sound/soc/codecs/wsa884x.c
index 07d8a2645404..2484d4b8e2d9 100644
--- a/sound/soc/codecs/wsa884x.c
+++ b/sound/soc/codecs/wsa884x.c
@@ -1941,7 +1941,6 @@ static int wsa884x_get_temp(struct wsa884x_priv *wsa884x, long *temp)
 	}
 
 out:
-	pm_runtime_mark_last_busy(wsa884x->dev);
 	pm_runtime_put_autosuspend(wsa884x->dev);
 
 	return ret;
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 72/80] ASoC: Intel: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (5 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 71/80] ASoC: codecs: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04  7:54 ` [PATCH 73/80] ASoC: component: " Sakari Ailus
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Cezary Rojewski, Liam Girdwood, Peter Ujfalusi, Bard Liao,
	Ranjani Sridharan, Kai Vehmanen, Pierre-Louis Bossart, Mark Brown,
	Jaroslav Kysela, Takashi Iwai, Sakari Ailus,
	Dr. David Alan Gilbert, Amadeusz Sławiński,
	Philipp Stanner, Al Viro, Ethan Carter Edwards, Jerome Brunet,
	Henry Martin
  Cc: linux-sound, linux-kernel

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/soc/intel/atom/sst/sst_pvt.c | 1 -
 sound/soc/intel/avs/core.c         | 1 -
 sound/soc/intel/avs/debugfs.c      | 2 --
 sound/soc/intel/avs/ipc.c          | 1 -
 sound/soc/intel/avs/pcm.c          | 1 -
 sound/soc/intel/catpt/pcm.c        | 6 ------
 sound/soc/intel/catpt/sysfs.c      | 1 -
 7 files changed, 13 deletions(-)

diff --git a/sound/soc/intel/atom/sst/sst_pvt.c b/sound/soc/intel/atom/sst/sst_pvt.c
index 5d08f7d803f9..c01b29616ebc 100644
--- a/sound/soc/intel/atom/sst/sst_pvt.c
+++ b/sound/soc/intel/atom/sst/sst_pvt.c
@@ -259,7 +259,6 @@ int sst_pm_runtime_put(struct intel_sst_drv *sst_drv)
 {
 	int ret;
 
-	pm_runtime_mark_last_busy(sst_drv->dev);
 	ret = pm_runtime_put_autosuspend(sst_drv->dev);
 	if (ret < 0)
 		return ret;
diff --git a/sound/soc/intel/avs/core.c b/sound/soc/intel/avs/core.c
index ec1b3f55cb5c..7af324753673 100644
--- a/sound/soc/intel/avs/core.c
+++ b/sound/soc/intel/avs/core.c
@@ -231,7 +231,6 @@ static void avs_hda_probe_work(struct work_struct *work)
 	/* configure PM */
 	pm_runtime_set_autosuspend_delay(bus->dev, 2000);
 	pm_runtime_use_autosuspend(bus->dev);
-	pm_runtime_mark_last_busy(bus->dev);
 	pm_runtime_put_autosuspend(bus->dev);
 	pm_runtime_allow(bus->dev);
 }
diff --git a/sound/soc/intel/avs/debugfs.c b/sound/soc/intel/avs/debugfs.c
index c625cf879f17..f508f215ecd2 100644
--- a/sound/soc/intel/avs/debugfs.c
+++ b/sound/soc/intel/avs/debugfs.c
@@ -315,7 +315,6 @@ static int enable_logs(struct avs_dev *adev, u32 resource_mask, u32 *priorities)
 	if (!adev->logged_resources) {
 		avs_dsp_enable_d0ix(adev);
 err_d0ix:
-		pm_runtime_mark_last_busy(adev->dev);
 		pm_runtime_put_autosuspend(adev->dev);
 	}
 
@@ -342,7 +341,6 @@ static int disable_logs(struct avs_dev *adev, u32 resource_mask)
 	/* If that's the last resource, allow for D3. */
 	if (!adev->logged_resources) {
 		avs_dsp_enable_d0ix(adev);
-		pm_runtime_mark_last_busy(adev->dev);
 		pm_runtime_put_autosuspend(adev->dev);
 	}
 
diff --git a/sound/soc/intel/avs/ipc.c b/sound/soc/intel/avs/ipc.c
index 0314f9d4ea5f..6bfb9d1a1ca8 100644
--- a/sound/soc/intel/avs/ipc.c
+++ b/sound/soc/intel/avs/ipc.c
@@ -141,7 +141,6 @@ static void avs_dsp_recovery(struct avs_dev *adev)
 	if (ret < 0)
 		dev_err(adev->dev, "dsp reboot failed: %d\n", ret);
 
-	pm_runtime_mark_last_busy(adev->dev);
 	pm_runtime_enable(adev->dev);
 	pm_request_autosuspend(adev->dev);
 
diff --git a/sound/soc/intel/avs/pcm.c b/sound/soc/intel/avs/pcm.c
index ccf90428126d..3a22a8cb5185 100644
--- a/sound/soc/intel/avs/pcm.c
+++ b/sound/soc/intel/avs/pcm.c
@@ -979,7 +979,6 @@ static int avs_component_load_libraries(struct avs_soc_component *acomp)
 	if (!ret)
 		ret = avs_module_info_init(adev, false);
 
-	pm_runtime_mark_last_busy(adev->dev);
 	pm_runtime_put_autosuspend(adev->dev);
 
 	return ret;
diff --git a/sound/soc/intel/catpt/pcm.c b/sound/soc/intel/catpt/pcm.c
index 81a2f0339e05..46acb7fdc547 100644
--- a/sound/soc/intel/catpt/pcm.c
+++ b/sound/soc/intel/catpt/pcm.c
@@ -673,7 +673,6 @@ static int catpt_dai_pcm_new(struct snd_soc_pcm_runtime *rtm,
 
 	ret = catpt_ipc_set_device_format(cdev, &devfmt);
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	if (ret)
@@ -871,7 +870,6 @@ static int catpt_mixer_volume_get(struct snd_kcontrol *kcontrol,
 		ucontrol->value.integer.value[i] = dspvol_to_ctlvol(dspvol);
 	}
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	return 0;
@@ -892,7 +890,6 @@ static int catpt_mixer_volume_put(struct snd_kcontrol *kcontrol,
 	ret = catpt_set_dspvol(cdev, cdev->mixer.mixer_hw_id,
 			       ucontrol->value.integer.value);
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	return ret;
@@ -927,7 +924,6 @@ static int catpt_stream_volume_get(struct snd_kcontrol *kcontrol,
 		ucontrol->value.integer.value[i] = dspvol_to_ctlvol(dspvol);
 	}
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	return 0;
@@ -958,7 +954,6 @@ static int catpt_stream_volume_put(struct snd_kcontrol *kcontrol,
 	ret = catpt_set_dspvol(cdev, stream->info.stream_hw_id,
 			       ucontrol->value.integer.value);
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	if (ret)
@@ -1035,7 +1030,6 @@ static int catpt_loopback_switch_put(struct snd_kcontrol *kcontrol,
 
 	ret = catpt_ipc_mute_loopback(cdev, stream->info.stream_hw_id, mute);
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	if (ret)
diff --git a/sound/soc/intel/catpt/sysfs.c b/sound/soc/intel/catpt/sysfs.c
index 936ac9d503ff..048253002ec8 100644
--- a/sound/soc/intel/catpt/sysfs.c
+++ b/sound/soc/intel/catpt/sysfs.c
@@ -21,7 +21,6 @@ static ssize_t fw_version_show(struct device *dev,
 
 	ret = catpt_ipc_get_fw_version(cdev, &version);
 
-	pm_runtime_mark_last_busy(cdev->dev);
 	pm_runtime_put_autosuspend(cdev->dev);
 
 	if (ret)
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 73/80] ASoC: component: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (6 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 72/80] ASoC: Intel: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04  7:54 ` [PATCH 74/80] ASoC: SOF: " Sakari Ailus
  2025-07-04  7:55 ` [PATCH 75/80] ALSA: intel_hdmi: " Sakari Ailus
  9 siblings, 0 replies; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai
  Cc: linux-sound, linux-kernel

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/soc/soc-component.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sound/soc/soc-component.c b/sound/soc/soc-component.c
index 25f5e543ae8d..65c495094024 100644
--- a/sound/soc/soc-component.c
+++ b/sound/soc/soc-component.c
@@ -1278,7 +1278,6 @@ void snd_soc_pcm_component_pm_runtime_put(struct snd_soc_pcm_runtime *rtd,
 		if (rollback && !soc_component_mark_match(component, stream, pm))
 			continue;
 
-		pm_runtime_mark_last_busy(component->dev);
 		pm_runtime_put_autosuspend(component->dev);
 
 		/* remove marked stream */
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 74/80] ASoC: SOF: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (7 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 73/80] ASoC: component: " Sakari Ailus
@ 2025-07-04  7:54 ` Sakari Ailus
  2025-07-04  8:26   ` Péter Ujfalusi
  2025-07-04  7:55 ` [PATCH 75/80] ALSA: intel_hdmi: " Sakari Ailus
  9 siblings, 1 reply; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:54 UTC (permalink / raw)
  To: Liam Girdwood, Peter Ujfalusi, Bard Liao, Ranjani Sridharan,
	Daniel Baluta, Kai Vehmanen, Pierre-Louis Bossart, Mark Brown,
	Jaroslav Kysela, Takashi Iwai
  Cc: sound-open-firmware, linux-sound, linux-kernel

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/soc/sof/control.c                        | 1 -
 sound/soc/sof/debug.c                          | 1 -
 sound/soc/sof/ipc3-dtrace.c                    | 1 -
 sound/soc/sof/ipc4-loader.c                    | 1 -
 sound/soc/sof/pcm.c                            | 1 -
 sound/soc/sof/sof-client-ipc-flood-test.c      | 1 -
 sound/soc/sof/sof-client-ipc-kernel-injector.c | 1 -
 sound/soc/sof/sof-client-ipc-msg-injector.c    | 1 -
 sound/soc/sof/sof-client-probes.c              | 3 ---
 9 files changed, 11 deletions(-)

diff --git a/sound/soc/sof/control.c b/sound/soc/sof/control.c
index 463d418e7200..a3fd1d523c09 100644
--- a/sound/soc/sof/control.c
+++ b/sound/soc/sof/control.c
@@ -196,7 +196,6 @@ int snd_sof_bytes_ext_volatile_get(struct snd_kcontrol *kcontrol, unsigned int _
 	if (tplg_ops && tplg_ops->control && tplg_ops->control->bytes_ext_volatile_get)
 		ret = tplg_ops->control->bytes_ext_volatile_get(scontrol, binary_data, size);
 
-	pm_runtime_mark_last_busy(scomp->dev);
 	err = pm_runtime_put_autosuspend(scomp->dev);
 	if (err < 0)
 		dev_err_ratelimited(scomp->dev, "%s: failed to idle %d\n", __func__, err);
diff --git a/sound/soc/sof/debug.c b/sound/soc/sof/debug.c
index d0ffa1d71145..b24943a65c89 100644
--- a/sound/soc/sof/debug.c
+++ b/sound/soc/sof/debug.c
@@ -217,7 +217,6 @@ static int memory_info_update(struct snd_sof_dev *sdev, char *buf, size_t buff_s
 	}
 
 	ret = sof_ipc_tx_message(sdev->ipc, &msg, msg.size, reply, SOF_IPC_MSG_MAX_SIZE);
-	pm_runtime_mark_last_busy(sdev->dev);
 	pm_runtime_put_autosuspend(sdev->dev);
 	if (ret < 0 || reply->rhdr.error < 0) {
 		ret = min(ret, reply->rhdr.error);
diff --git a/sound/soc/sof/ipc3-dtrace.c b/sound/soc/sof/ipc3-dtrace.c
index 744a91a150bc..e5c8fec173c4 100644
--- a/sound/soc/sof/ipc3-dtrace.c
+++ b/sound/soc/sof/ipc3-dtrace.c
@@ -172,7 +172,6 @@ static int ipc3_trace_update_filter(struct snd_sof_dev *sdev, int num_elems,
 		goto error;
 	}
 	ret = sof_ipc_tx_message_no_reply(sdev->ipc, msg, msg->hdr.size);
-	pm_runtime_mark_last_busy(sdev->dev);
 	pm_runtime_put_autosuspend(sdev->dev);
 
 error:
diff --git a/sound/soc/sof/ipc4-loader.c b/sound/soc/sof/ipc4-loader.c
index ee61394e73d7..b0d293f62d1c 100644
--- a/sound/soc/sof/ipc4-loader.c
+++ b/sound/soc/sof/ipc4-loader.c
@@ -236,7 +236,6 @@ static int sof_ipc4_load_library(struct snd_sof_dev *sdev, unsigned long lib_id,
 
 	ret = ipc4_data->load_library(sdev, fw_lib, false);
 
-	pm_runtime_mark_last_busy(sdev->dev);
 	err = pm_runtime_put_autosuspend(sdev->dev);
 	if (err < 0)
 		dev_err_ratelimited(sdev->dev, "%s: pm_runtime idle failed: %d\n",
diff --git a/sound/soc/sof/pcm.c b/sound/soc/sof/pcm.c
index 090ea3a76892..fe43de1fe96c 100644
--- a/sound/soc/sof/pcm.c
+++ b/sound/soc/sof/pcm.c
@@ -712,7 +712,6 @@ static int sof_pcm_probe(struct snd_soc_component *component)
 			ret);
 
 pm_error:
-	pm_runtime_mark_last_busy(component->dev);
 	pm_runtime_put_autosuspend(component->dev);
 
 	return ret;
diff --git a/sound/soc/sof/sof-client-ipc-flood-test.c b/sound/soc/sof/sof-client-ipc-flood-test.c
index 11b6f7da2882..373f3a125372 100644
--- a/sound/soc/sof/sof-client-ipc-flood-test.c
+++ b/sound/soc/sof/sof-client-ipc-flood-test.c
@@ -223,7 +223,6 @@ static ssize_t sof_ipc_flood_dfs_write(struct file *file, const char __user *buf
 	ret = sof_debug_ipc_flood_test(cdev, flood_duration_test,
 				       ipc_duration_ms, ipc_count);
 
-	pm_runtime_mark_last_busy(dev);
 	err = pm_runtime_put_autosuspend(dev);
 	if (err < 0)
 		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
diff --git a/sound/soc/sof/sof-client-ipc-kernel-injector.c b/sound/soc/sof/sof-client-ipc-kernel-injector.c
index 8b28c3dc920c..249bd2d6c8d2 100644
--- a/sound/soc/sof/sof-client-ipc-kernel-injector.c
+++ b/sound/soc/sof/sof-client-ipc-kernel-injector.c
@@ -65,7 +65,6 @@ static ssize_t sof_kernel_msg_inject_dfs_write(struct file *file, const char __u
 
 	sof_client_ipc_rx_message(cdev, hdr, priv->kernel_buffer);
 
-	pm_runtime_mark_last_busy(dev);
 	ret = pm_runtime_put_autosuspend(dev);
 	if (ret < 0)
 		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", ret);
diff --git a/sound/soc/sof/sof-client-ipc-msg-injector.c b/sound/soc/sof/sof-client-ipc-msg-injector.c
index ba7ca1c5027f..9c8a0fbfb8df 100644
--- a/sound/soc/sof/sof-client-ipc-msg-injector.c
+++ b/sound/soc/sof/sof-client-ipc-msg-injector.c
@@ -137,7 +137,6 @@ static int sof_msg_inject_send_message(struct sof_client_dev *cdev)
 	if (ret)
 		dev_err(dev, "IPC message send failed: %d\n", ret);
 
-	pm_runtime_mark_last_busy(dev);
 	err = pm_runtime_put_autosuspend(dev);
 	if (err < 0)
 		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
diff --git a/sound/soc/sof/sof-client-probes.c b/sound/soc/sof/sof-client-probes.c
index aff9ce980429..663c0d3c314c 100644
--- a/sound/soc/sof/sof-client-probes.c
+++ b/sound/soc/sof/sof-client-probes.c
@@ -238,7 +238,6 @@ static ssize_t sof_probes_dfs_points_read(struct file *file, char __user *to,
 	kfree(desc);
 
 pm_error:
-	pm_runtime_mark_last_busy(dev);
 	err = pm_runtime_put_autosuspend(dev);
 	if (err < 0)
 		dev_err_ratelimited(dev, "debugfs read failed to idle %d\n", err);
@@ -289,7 +288,6 @@ sof_probes_dfs_points_write(struct file *file, const char __user *from,
 	if (!ret)
 		ret = count;
 
-	pm_runtime_mark_last_busy(dev);
 	err = pm_runtime_put_autosuspend(dev);
 	if (err < 0)
 		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
@@ -337,7 +335,6 @@ sof_probes_dfs_points_remove_write(struct file *file, const char __user *from,
 	if (!ret)
 		ret = count;
 
-	pm_runtime_mark_last_busy(dev);
 	err = pm_runtime_put_autosuspend(dev);
 	if (err < 0)
 		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* [PATCH 75/80] ALSA: intel_hdmi: Remove redundant pm_runtime_mark_last_busy() calls
       [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
                   ` (8 preceding siblings ...)
  2025-07-04  7:54 ` [PATCH 74/80] ASoC: SOF: " Sakari Ailus
@ 2025-07-04  7:55 ` Sakari Ailus
  2025-07-04 11:45   ` Takashi Iwai
  9 siblings, 1 reply; 21+ messages in thread
From: Sakari Ailus @ 2025-07-04  7:55 UTC (permalink / raw)
  To: Jaroslav Kysela, Takashi Iwai, Sakari Ailus, Thorsten Blum
  Cc: linux-sound, linux-kernel

pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
pm_runtime_mark_last_busy().

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
---
The cover letter of the set can be found here
<URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.

In brief, this patch depends on PM runtime patches adding marking the last
busy timestamp in autosuspend related functions. The patches are here, on
rc2:

        git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
                pm-runtime-6.17-rc1

 sound/x86/intel_hdmi_audio.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/sound/x86/intel_hdmi_audio.c b/sound/x86/intel_hdmi_audio.c
index fe5cb4139088..cc54539c6030 100644
--- a/sound/x86/intel_hdmi_audio.c
+++ b/sound/x86/intel_hdmi_audio.c
@@ -1102,7 +1102,6 @@ static int had_pcm_open(struct snd_pcm_substream *substream)
 
 	return retval;
  error:
-	pm_runtime_mark_last_busy(intelhaddata->dev);
 	pm_runtime_put_autosuspend(intelhaddata->dev);
 	return retval;
 }
@@ -1127,7 +1126,6 @@ static int had_pcm_close(struct snd_pcm_substream *substream)
 	}
 	spin_unlock_irq(&intelhaddata->had_spinlock);
 
-	pm_runtime_mark_last_busy(intelhaddata->dev);
 	pm_runtime_put_autosuspend(intelhaddata->dev);
 	return 0;
 }
@@ -1589,7 +1587,6 @@ static void had_audio_wq(struct work_struct *work)
 	}
 
 	mutex_unlock(&ctx->mutex);
-	pm_runtime_mark_last_busy(ctx->dev);
 	pm_runtime_put_autosuspend(ctx->dev);
 }
 
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 21+ messages in thread

* Re: [PATCH 74/80] ASoC: SOF: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 74/80] ASoC: SOF: " Sakari Ailus
@ 2025-07-04  8:26   ` Péter Ujfalusi
  0 siblings, 0 replies; 21+ messages in thread
From: Péter Ujfalusi @ 2025-07-04  8:26 UTC (permalink / raw)
  To: Sakari Ailus, Liam Girdwood, Bard Liao, Ranjani Sridharan,
	Daniel Baluta, Kai Vehmanen, Pierre-Louis Bossart, Mark Brown,
	Jaroslav Kysela, Takashi Iwai
  Cc: sound-open-firmware, linux-sound, linux-kernel



On 04/07/2025 10:54, Sakari Ailus wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().

Acked-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---
> The cover letter of the set can be found here
> <URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.
> 
> In brief, this patch depends on PM runtime patches adding marking the last
> busy timestamp in autosuspend related functions. The patches are here, on
> rc2:
> 
>         git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
>                 pm-runtime-6.17-rc1
> 
>  sound/soc/sof/control.c                        | 1 -
>  sound/soc/sof/debug.c                          | 1 -
>  sound/soc/sof/ipc3-dtrace.c                    | 1 -
>  sound/soc/sof/ipc4-loader.c                    | 1 -
>  sound/soc/sof/pcm.c                            | 1 -
>  sound/soc/sof/sof-client-ipc-flood-test.c      | 1 -
>  sound/soc/sof/sof-client-ipc-kernel-injector.c | 1 -
>  sound/soc/sof/sof-client-ipc-msg-injector.c    | 1 -
>  sound/soc/sof/sof-client-probes.c              | 3 ---
>  9 files changed, 11 deletions(-)
> 
> diff --git a/sound/soc/sof/control.c b/sound/soc/sof/control.c
> index 463d418e7200..a3fd1d523c09 100644
> --- a/sound/soc/sof/control.c
> +++ b/sound/soc/sof/control.c
> @@ -196,7 +196,6 @@ int snd_sof_bytes_ext_volatile_get(struct snd_kcontrol *kcontrol, unsigned int _
>  	if (tplg_ops && tplg_ops->control && tplg_ops->control->bytes_ext_volatile_get)
>  		ret = tplg_ops->control->bytes_ext_volatile_get(scontrol, binary_data, size);
>  
> -	pm_runtime_mark_last_busy(scomp->dev);
>  	err = pm_runtime_put_autosuspend(scomp->dev);
>  	if (err < 0)
>  		dev_err_ratelimited(scomp->dev, "%s: failed to idle %d\n", __func__, err);
> diff --git a/sound/soc/sof/debug.c b/sound/soc/sof/debug.c
> index d0ffa1d71145..b24943a65c89 100644
> --- a/sound/soc/sof/debug.c
> +++ b/sound/soc/sof/debug.c
> @@ -217,7 +217,6 @@ static int memory_info_update(struct snd_sof_dev *sdev, char *buf, size_t buff_s
>  	}
>  
>  	ret = sof_ipc_tx_message(sdev->ipc, &msg, msg.size, reply, SOF_IPC_MSG_MAX_SIZE);
> -	pm_runtime_mark_last_busy(sdev->dev);
>  	pm_runtime_put_autosuspend(sdev->dev);
>  	if (ret < 0 || reply->rhdr.error < 0) {
>  		ret = min(ret, reply->rhdr.error);
> diff --git a/sound/soc/sof/ipc3-dtrace.c b/sound/soc/sof/ipc3-dtrace.c
> index 744a91a150bc..e5c8fec173c4 100644
> --- a/sound/soc/sof/ipc3-dtrace.c
> +++ b/sound/soc/sof/ipc3-dtrace.c
> @@ -172,7 +172,6 @@ static int ipc3_trace_update_filter(struct snd_sof_dev *sdev, int num_elems,
>  		goto error;
>  	}
>  	ret = sof_ipc_tx_message_no_reply(sdev->ipc, msg, msg->hdr.size);
> -	pm_runtime_mark_last_busy(sdev->dev);
>  	pm_runtime_put_autosuspend(sdev->dev);
>  
>  error:
> diff --git a/sound/soc/sof/ipc4-loader.c b/sound/soc/sof/ipc4-loader.c
> index ee61394e73d7..b0d293f62d1c 100644
> --- a/sound/soc/sof/ipc4-loader.c
> +++ b/sound/soc/sof/ipc4-loader.c
> @@ -236,7 +236,6 @@ static int sof_ipc4_load_library(struct snd_sof_dev *sdev, unsigned long lib_id,
>  
>  	ret = ipc4_data->load_library(sdev, fw_lib, false);
>  
> -	pm_runtime_mark_last_busy(sdev->dev);
>  	err = pm_runtime_put_autosuspend(sdev->dev);
>  	if (err < 0)
>  		dev_err_ratelimited(sdev->dev, "%s: pm_runtime idle failed: %d\n",
> diff --git a/sound/soc/sof/pcm.c b/sound/soc/sof/pcm.c
> index 090ea3a76892..fe43de1fe96c 100644
> --- a/sound/soc/sof/pcm.c
> +++ b/sound/soc/sof/pcm.c
> @@ -712,7 +712,6 @@ static int sof_pcm_probe(struct snd_soc_component *component)
>  			ret);
>  
>  pm_error:
> -	pm_runtime_mark_last_busy(component->dev);
>  	pm_runtime_put_autosuspend(component->dev);
>  
>  	return ret;
> diff --git a/sound/soc/sof/sof-client-ipc-flood-test.c b/sound/soc/sof/sof-client-ipc-flood-test.c
> index 11b6f7da2882..373f3a125372 100644
> --- a/sound/soc/sof/sof-client-ipc-flood-test.c
> +++ b/sound/soc/sof/sof-client-ipc-flood-test.c
> @@ -223,7 +223,6 @@ static ssize_t sof_ipc_flood_dfs_write(struct file *file, const char __user *buf
>  	ret = sof_debug_ipc_flood_test(cdev, flood_duration_test,
>  				       ipc_duration_ms, ipc_count);
>  
> -	pm_runtime_mark_last_busy(dev);
>  	err = pm_runtime_put_autosuspend(dev);
>  	if (err < 0)
>  		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
> diff --git a/sound/soc/sof/sof-client-ipc-kernel-injector.c b/sound/soc/sof/sof-client-ipc-kernel-injector.c
> index 8b28c3dc920c..249bd2d6c8d2 100644
> --- a/sound/soc/sof/sof-client-ipc-kernel-injector.c
> +++ b/sound/soc/sof/sof-client-ipc-kernel-injector.c
> @@ -65,7 +65,6 @@ static ssize_t sof_kernel_msg_inject_dfs_write(struct file *file, const char __u
>  
>  	sof_client_ipc_rx_message(cdev, hdr, priv->kernel_buffer);
>  
> -	pm_runtime_mark_last_busy(dev);
>  	ret = pm_runtime_put_autosuspend(dev);
>  	if (ret < 0)
>  		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", ret);
> diff --git a/sound/soc/sof/sof-client-ipc-msg-injector.c b/sound/soc/sof/sof-client-ipc-msg-injector.c
> index ba7ca1c5027f..9c8a0fbfb8df 100644
> --- a/sound/soc/sof/sof-client-ipc-msg-injector.c
> +++ b/sound/soc/sof/sof-client-ipc-msg-injector.c
> @@ -137,7 +137,6 @@ static int sof_msg_inject_send_message(struct sof_client_dev *cdev)
>  	if (ret)
>  		dev_err(dev, "IPC message send failed: %d\n", ret);
>  
> -	pm_runtime_mark_last_busy(dev);
>  	err = pm_runtime_put_autosuspend(dev);
>  	if (err < 0)
>  		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
> diff --git a/sound/soc/sof/sof-client-probes.c b/sound/soc/sof/sof-client-probes.c
> index aff9ce980429..663c0d3c314c 100644
> --- a/sound/soc/sof/sof-client-probes.c
> +++ b/sound/soc/sof/sof-client-probes.c
> @@ -238,7 +238,6 @@ static ssize_t sof_probes_dfs_points_read(struct file *file, char __user *to,
>  	kfree(desc);
>  
>  pm_error:
> -	pm_runtime_mark_last_busy(dev);
>  	err = pm_runtime_put_autosuspend(dev);
>  	if (err < 0)
>  		dev_err_ratelimited(dev, "debugfs read failed to idle %d\n", err);
> @@ -289,7 +288,6 @@ sof_probes_dfs_points_write(struct file *file, const char __user *from,
>  	if (!ret)
>  		ret = count;
>  
> -	pm_runtime_mark_last_busy(dev);
>  	err = pm_runtime_put_autosuspend(dev);
>  	if (err < 0)
>  		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);
> @@ -337,7 +335,6 @@ sof_probes_dfs_points_remove_write(struct file *file, const char __user *from,
>  	if (!ret)
>  		ret = count;
>  
> -	pm_runtime_mark_last_busy(dev);
>  	err = pm_runtime_put_autosuspend(dev);
>  	if (err < 0)
>  		dev_err_ratelimited(dev, "debugfs write failed to idle %d\n", err);

-- 
Péter


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 75/80] ALSA: intel_hdmi: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:55 ` [PATCH 75/80] ALSA: intel_hdmi: " Sakari Ailus
@ 2025-07-04 11:45   ` Takashi Iwai
  2025-07-06  8:26     ` Takashi Iwai
  0 siblings, 1 reply; 21+ messages in thread
From: Takashi Iwai @ 2025-07-04 11:45 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Jaroslav Kysela, Takashi Iwai, Thorsten Blum, linux-sound,
	linux-kernel

On Fri, 04 Jul 2025 09:55:00 +0200,
Sakari Ailus wrote:
> 
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>

Acked-by: Takashi Iwai <tiwai@suse.de>


thanks,

Takashi

> ---
> The cover letter of the set can be found here
> <URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.
> 
> In brief, this patch depends on PM runtime patches adding marking the last
> busy timestamp in autosuspend related functions. The patches are here, on
> rc2:
> 
>         git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
>                 pm-runtime-6.17-rc1
> 
>  sound/x86/intel_hdmi_audio.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/sound/x86/intel_hdmi_audio.c b/sound/x86/intel_hdmi_audio.c
> index fe5cb4139088..cc54539c6030 100644
> --- a/sound/x86/intel_hdmi_audio.c
> +++ b/sound/x86/intel_hdmi_audio.c
> @@ -1102,7 +1102,6 @@ static int had_pcm_open(struct snd_pcm_substream *substream)
>  
>  	return retval;
>   error:
> -	pm_runtime_mark_last_busy(intelhaddata->dev);
>  	pm_runtime_put_autosuspend(intelhaddata->dev);
>  	return retval;
>  }
> @@ -1127,7 +1126,6 @@ static int had_pcm_close(struct snd_pcm_substream *substream)
>  	}
>  	spin_unlock_irq(&intelhaddata->had_spinlock);
>  
> -	pm_runtime_mark_last_busy(intelhaddata->dev);
>  	pm_runtime_put_autosuspend(intelhaddata->dev);
>  	return 0;
>  }
> @@ -1589,7 +1587,6 @@ static void had_audio_wq(struct work_struct *work)
>  	}
>  
>  	mutex_unlock(&ctx->mutex);
> -	pm_runtime_mark_last_busy(ctx->dev);
>  	pm_runtime_put_autosuspend(ctx->dev);
>  }
>  
> -- 
> 2.39.5
> 

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 69/80] ALSA: hda: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 69/80] ALSA: hda: " Sakari Ailus
@ 2025-07-04 11:47   ` Takashi Iwai
  2025-07-04 11:52     ` Mark Brown
  0 siblings, 1 reply; 21+ messages in thread
From: Takashi Iwai @ 2025-07-04 11:47 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Jaroslav Kysela, Takashi Iwai, David Rhodes, Richard Fitzgerald,
	Shenghao Ding, Kevin Lu, Baojun Xu, Amadeusz Sławiński,
	Cezary Rojewski, Mark Brown, Andy Shevchenko, Dan Carpenter,
	Chen Ni, linux-sound, linux-kernel, patches

On Fri, 04 Jul 2025 09:54:55 +0200,
Sakari Ailus wrote:
> 
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>

Acked-by: Takashi Iwai <tiwai@suse.de>


thanks,

Takashi

> ---
> The cover letter of the set can be found here
> <URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.
> 
> In brief, this patch depends on PM runtime patches adding marking the last
> busy timestamp in autosuspend related functions. The patches are here, on
> rc2:
> 
>         git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
>                 pm-runtime-6.17-rc1
> 
>  sound/hda/hdac_device.c         | 1 -
>  sound/pci/hda/cs35l41_hda.c     | 4 ----
>  sound/pci/hda/cs35l56_hda.c     | 1 -
>  sound/pci/hda/tas2781_hda_i2c.c | 3 ---
>  sound/pci/hda/tas2781_hda_spi.c | 4 ----
>  5 files changed, 13 deletions(-)
> 
> diff --git a/sound/hda/hdac_device.c b/sound/hda/hdac_device.c
> index 0053831eed2d..a02dce5f6a88 100644
> --- a/sound/hda/hdac_device.c
> +++ b/sound/hda/hdac_device.c
> @@ -581,7 +581,6 @@ int snd_hdac_power_down(struct hdac_device *codec)
>  {
>  	struct device *dev = &codec->dev;
>  
> -	pm_runtime_mark_last_busy(dev);
>  	return pm_runtime_put_autosuspend(dev);
>  }
>  EXPORT_SYMBOL_GPL(snd_hdac_power_down);
> diff --git a/sound/pci/hda/cs35l41_hda.c b/sound/pci/hda/cs35l41_hda.c
> index c2cf3813872a..fc3f9ed3be13 100644
> --- a/sound/pci/hda/cs35l41_hda.c
> +++ b/sound/pci/hda/cs35l41_hda.c
> @@ -836,7 +836,6 @@ static void cs35l41_hda_playback_hook(struct device *dev, int action)
>  		 * Playback must be finished for all amps before we start runtime suspend.
>  		 * This ensures no amps are playing back when we start putting them to sleep.
>  		 */
> -		pm_runtime_mark_last_busy(dev);
>  		pm_runtime_put_autosuspend(dev);
>  		break;
>  	default:
> @@ -1284,7 +1283,6 @@ static void cs35l41_fw_load_work(struct work_struct *work)
>  	cs35l41->fw_request_ongoing = false;
>  	mutex_unlock(&cs35l41->fw_mutex);
>  
> -	pm_runtime_mark_last_busy(cs35l41->dev);
>  	pm_runtime_put_autosuspend(cs35l41->dev);
>  }
>  
> @@ -1515,7 +1513,6 @@ static int cs35l41_hda_bind(struct device *dev, struct device *master, void *mas
>  		dev_warn(dev, "Unable to create device link\n");
>  	unlock_system_sleep(sleep_flags);
>  
> -	pm_runtime_mark_last_busy(dev);
>  	pm_runtime_put_autosuspend(dev);
>  
>  	dev_info(cs35l41->dev,
> @@ -2036,7 +2033,6 @@ int cs35l41_hda_probe(struct device *dev, const char *device_name, int id, int i
>  
>  	pm_runtime_set_autosuspend_delay(cs35l41->dev, 3000);
>  	pm_runtime_use_autosuspend(cs35l41->dev);
> -	pm_runtime_mark_last_busy(cs35l41->dev);
>  	pm_runtime_set_active(cs35l41->dev);
>  	pm_runtime_get_noresume(cs35l41->dev);
>  	pm_runtime_enable(cs35l41->dev);
> diff --git a/sound/pci/hda/cs35l56_hda.c b/sound/pci/hda/cs35l56_hda.c
> index 3f2fd32f4ad9..0391bbffed7d 100644
> --- a/sound/pci/hda/cs35l56_hda.c
> +++ b/sound/pci/hda/cs35l56_hda.c
> @@ -89,7 +89,6 @@ static void cs35l56_hda_pause(struct cs35l56_hda *cs35l56)
>  			  BIT(CS35L56_ASP_TX1_EN_SHIFT) | BIT(CS35L56_ASP_TX2_EN_SHIFT) |
>  			  BIT(CS35L56_ASP_TX3_EN_SHIFT) | BIT(CS35L56_ASP_TX4_EN_SHIFT));
>  
> -	pm_runtime_mark_last_busy(cs35l56->base.dev);
>  	pm_runtime_put_autosuspend(cs35l56->base.dev);
>  }
>  
> diff --git a/sound/pci/hda/tas2781_hda_i2c.c b/sound/pci/hda/tas2781_hda_i2c.c
> index b9cdbca951e4..8a461acbc3b9 100644
> --- a/sound/pci/hda/tas2781_hda_i2c.c
> +++ b/sound/pci/hda/tas2781_hda_i2c.c
> @@ -157,7 +157,6 @@ static void tas2781_hda_playback_hook(struct device *dev, int action)
>  		tas_hda->priv->playback_started = false;
>  		mutex_unlock(&tas_hda->priv->codec_lock);
>  
> -		pm_runtime_mark_last_busy(dev);
>  		pm_runtime_put_autosuspend(dev);
>  		break;
>  	default:
> @@ -483,7 +482,6 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
>  out:
>  	mutex_unlock(&tas_hda->priv->codec_lock);
>  	release_firmware(fmw);
> -	pm_runtime_mark_last_busy(tas_hda->dev);
>  	pm_runtime_put_autosuspend(tas_hda->dev);
>  }
>  
> @@ -526,7 +524,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
>  	if (!ret)
>  		comp->playback_hook = tas2781_hda_playback_hook;
>  
> -	pm_runtime_mark_last_busy(dev);
>  	pm_runtime_put_autosuspend(dev);
>  
>  	return ret;
> diff --git a/sound/pci/hda/tas2781_hda_spi.c b/sound/pci/hda/tas2781_hda_spi.c
> index 5c03e9d2283a..c4b9a3c1a7f0 100644
> --- a/sound/pci/hda/tas2781_hda_spi.c
> +++ b/sound/pci/hda/tas2781_hda_spi.c
> @@ -400,7 +400,6 @@ static void tas2781_hda_playback_hook(struct device *dev, int action)
>  		guard(mutex)(&tas_priv->codec_lock);
>  		if (tas_priv->fw_state == TASDEVICE_DSP_FW_ALL_OK)
>  			tasdevice_tuning_switch(tas_priv, 1);
> -		pm_runtime_mark_last_busy(dev);
>  		pm_runtime_put_autosuspend(dev);
>  	}
>  }
> @@ -698,7 +697,6 @@ static void tasdev_fw_ready(const struct firmware *fmw, void *context)
>  	tas2781_save_calibration(tas_hda);
>  out:
>  	release_firmware(fmw);
> -	pm_runtime_mark_last_busy(tas_hda->priv->dev);
>  	pm_runtime_put_autosuspend(tas_hda->priv->dev);
>  }
>  
> @@ -731,7 +729,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
>  	if (!ret)
>  		comp->playback_hook = tas2781_hda_playback_hook;
>  
> -	pm_runtime_mark_last_busy(dev);
>  	pm_runtime_put_autosuspend(dev);
>  
>  	return ret;
> @@ -816,7 +813,6 @@ static int tas2781_hda_spi_probe(struct spi_device *spi)
>  
>  	pm_runtime_set_autosuspend_delay(tas_priv->dev, 3000);
>  	pm_runtime_use_autosuspend(tas_priv->dev);
> -	pm_runtime_mark_last_busy(tas_priv->dev);
>  	pm_runtime_set_active(tas_priv->dev);
>  	pm_runtime_get_noresume(tas_priv->dev);
>  	pm_runtime_enable(tas_priv->dev);
> -- 
> 2.39.5
> 

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 69/80] ALSA: hda: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04 11:47   ` Takashi Iwai
@ 2025-07-04 11:52     ` Mark Brown
  2025-07-04 11:58       ` Takashi Iwai
  0 siblings, 1 reply; 21+ messages in thread
From: Mark Brown @ 2025-07-04 11:52 UTC (permalink / raw)
  To: Takashi Iwai
  Cc: Sakari Ailus, Jaroslav Kysela, Takashi Iwai, David Rhodes,
	Richard Fitzgerald, Shenghao Ding, Kevin Lu, Baojun Xu,
	Amadeusz Sławiński, Cezary Rojewski, Andy Shevchenko,
	Dan Carpenter, Chen Ni, linux-sound, linux-kernel, patches

[-- Attachment #1: Type: text/plain, Size: 504 bytes --]

On Fri, Jul 04, 2025 at 01:47:26PM +0200, Takashi Iwai wrote:
> Sakari Ailus wrote:

> > pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> > pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> > to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> > pm_runtime_mark_last_busy().

> Acked-by: Takashi Iwai <tiwai@suse.de>

The suggestion in the cover letter was that we should apply these to our
trees after pulling a tag from Rafael's tree.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 69/80] ALSA: hda: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04 11:52     ` Mark Brown
@ 2025-07-04 11:58       ` Takashi Iwai
  2025-07-06  8:27         ` Takashi Iwai
  0 siblings, 1 reply; 21+ messages in thread
From: Takashi Iwai @ 2025-07-04 11:58 UTC (permalink / raw)
  To: Mark Brown
  Cc: Takashi Iwai, Sakari Ailus, Jaroslav Kysela, Takashi Iwai,
	David Rhodes, Richard Fitzgerald, Shenghao Ding, Kevin Lu,
	Baojun Xu, Amadeusz Sławiński, Cezary Rojewski,
	Andy Shevchenko, Dan Carpenter, Chen Ni, linux-sound,
	linux-kernel, patches

On Fri, 04 Jul 2025 13:52:50 +0200,
Mark Brown wrote:
> 
> On Fri, Jul 04, 2025 at 01:47:26PM +0200, Takashi Iwai wrote:
> > Sakari Ailus wrote:
> 
> > > pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> > > pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> > > to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> > > pm_runtime_mark_last_busy().
> 
> > Acked-by: Takashi Iwai <tiwai@suse.de>
> 
> The suggestion in the cover letter was that we should apply these to our
> trees after pulling a tag from Rafael's tree.

Ah thanks, that'd be even better, as we may have a big code
restructuring of HD-audio for 6.17, and this would be certainly
conflicting.


Takashi

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 75/80] ALSA: intel_hdmi: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04 11:45   ` Takashi Iwai
@ 2025-07-06  8:26     ` Takashi Iwai
  0 siblings, 0 replies; 21+ messages in thread
From: Takashi Iwai @ 2025-07-06  8:26 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Jaroslav Kysela, Takashi Iwai, Thorsten Blum, linux-sound,
	linux-kernel

On Fri, 04 Jul 2025 13:45:13 +0200,
Takashi Iwai wrote:
> 
> On Fri, 04 Jul 2025 09:55:00 +0200,
> Sakari Ailus wrote:
> > 
> > pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> > pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> > to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> > pm_runtime_mark_last_busy().
> > 
> > Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> 
> Acked-by: Takashi Iwai <tiwai@suse.de>

I merged now to for-next branch together with Rafael's preliminary
branch.


thanks,

Takashi

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 69/80] ALSA: hda: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04 11:58       ` Takashi Iwai
@ 2025-07-06  8:27         ` Takashi Iwai
  0 siblings, 0 replies; 21+ messages in thread
From: Takashi Iwai @ 2025-07-06  8:27 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Mark Brown, Jaroslav Kysela, Takashi Iwai, David Rhodes,
	Richard Fitzgerald, Shenghao Ding, Kevin Lu, Baojun Xu,
	Amadeusz Sławiński, Cezary Rojewski, Andy Shevchenko,
	Dan Carpenter, Chen Ni, linux-sound, linux-kernel, patches

On Fri, 04 Jul 2025 13:58:06 +0200,
Takashi Iwai wrote:
> 
> On Fri, 04 Jul 2025 13:52:50 +0200,
> Mark Brown wrote:
> > 
> > On Fri, Jul 04, 2025 at 01:47:26PM +0200, Takashi Iwai wrote:
> > > Sakari Ailus wrote:
> > 
> > > > pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> > > > pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> > > > to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> > > > pm_runtime_mark_last_busy().
> > 
> > > Acked-by: Takashi Iwai <tiwai@suse.de>
> > 
> > The suggestion in the cover letter was that we should apply these to our
> > trees after pulling a tag from Rafael's tree.
> 
> Ah thanks, that'd be even better, as we may have a big code
> restructuring of HD-audio for 6.17, and this would be certainly
> conflicting.

So now merged this to for-next branch.


thanks,

Takashi

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls Sakari Ailus
@ 2025-07-07  8:47   ` Charles Keepax
  2025-07-23  8:42   ` (subset) " Lee Jones
  1 sibling, 0 replies; 21+ messages in thread
From: Charles Keepax @ 2025-07-07  8:47 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Lee Jones, James Ogletree, Fred Treven, Ben Bright, David Rhodes,
	Richard Fitzgerald, patches, linux-kernel, linux-sound

On Fri, Jul 04, 2025 at 10:54:32AM +0300, Sakari Ailus wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---

Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 71/80] ASoC: codecs: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 71/80] ASoC: codecs: " Sakari Ailus
@ 2025-07-07  9:16   ` Charles Keepax
  0 siblings, 0 replies; 21+ messages in thread
From: Charles Keepax @ 2025-07-07  9:16 UTC (permalink / raw)
  To: Sakari Ailus
  Cc: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	David Rhodes, Richard Fitzgerald, Oder Chiou, Shenghao Ding,
	Kevin Lu, Baojun Xu, Srinivas Kandagatla, Cezary Rojewski,
	Amadeusz Sławiński, Krzysztof Kozlowski, patches,
	linux-sound, linux-kernel, linux-arm-msm

On Fri, Jul 04, 2025 at 10:54:56AM +0300, Sakari Ailus wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---
>  sound/soc/codecs/arizona-jack.c    | 2 --
>  sound/soc/codecs/cs35l41.c         | 2 --
>  sound/soc/codecs/cs35l45.c         | 1 -
>  sound/soc/codecs/cs35l56-sdw.c     | 1 -
>  sound/soc/codecs/cs35l56.c         | 1 -
>  sound/soc/codecs/cs42l42.c         | 1 -
>  sound/soc/codecs/cs42l43-jack.c    | 5 -----
>  sound/soc/codecs/cs42l43.c         | 2 --
>  sound/soc/codecs/cs48l32.c         | 1 -

For the Cirrus/Wolfson bits:

Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [PATCH 59/80] slimbus: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 59/80] slimbus: " Sakari Ailus
@ 2025-07-09  6:41   ` Srinivas Kandagatla
  0 siblings, 0 replies; 21+ messages in thread
From: Srinivas Kandagatla @ 2025-07-09  6:41 UTC (permalink / raw)
  To: Sakari Ailus, Srinivas Kandagatla
  Cc: linux-sound, linux-kernel, linux-arm-msm



On 7/4/25 8:54 AM, Sakari Ailus wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---

Acked-by: Srinivas Kandagatla <srini@kernel.org>

--srini

> The cover letter of the set can be found here
> <URL:https://lore.kernel.org/linux-pm/20250704075225.3212486-1-sakari.ailus@linux.intel.com>.
> 
> In brief, this patch depends on PM runtime patches adding marking the last
> busy timestamp in autosuspend related functions. The patches are here, on
> rc2:
> 
>         git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git \
>                 pm-runtime-6.17-rc1
> 
>  drivers/slimbus/core.c      | 1 -
>  drivers/slimbus/messaging.c | 2 --
>  drivers/slimbus/qcom-ctrl.c | 1 -
>  3 files changed, 4 deletions(-)
> 
> diff --git a/drivers/slimbus/core.c b/drivers/slimbus/core.c
> index 005fa2ef100f..31751ee4e400 100644
> --- a/drivers/slimbus/core.c
> +++ b/drivers/slimbus/core.c
> @@ -504,7 +504,6 @@ int slim_device_report_present(struct slim_controller *ctrl,
>  	ret = slim_device_alloc_laddr(sbdev, true);
>  
>  slimbus_not_active:
> -	pm_runtime_mark_last_busy(ctrl->dev);
>  	pm_runtime_put_autosuspend(ctrl->dev);
>  	return ret;
>  }
> diff --git a/drivers/slimbus/messaging.c b/drivers/slimbus/messaging.c
> index 6f01d944f9c6..44197493010e 100644
> --- a/drivers/slimbus/messaging.c
> +++ b/drivers/slimbus/messaging.c
> @@ -47,7 +47,6 @@ void slim_msg_response(struct slim_controller *ctrl, u8 *reply, u8 tid, u8 len)
>  		complete(txn->comp);
>  
>  	/* Remove runtime-pm vote now that response was received for TID txn */
> -	pm_runtime_mark_last_busy(ctrl->dev);
>  	pm_runtime_put_autosuspend(ctrl->dev);
>  }
>  EXPORT_SYMBOL_GPL(slim_msg_response);
> @@ -171,7 +170,6 @@ int slim_do_transfer(struct slim_controller *ctrl, struct slim_msg_txn *txn)
>  		 * remove runtime-pm vote if this was TX only, or
>  		 * if there was error during this transaction
>  		 */
> -		pm_runtime_mark_last_busy(ctrl->dev);
>  		pm_runtime_put_autosuspend(ctrl->dev);
>  	}
>  	return ret;
> diff --git a/drivers/slimbus/qcom-ctrl.c b/drivers/slimbus/qcom-ctrl.c
> index ab344f7472f2..880cf3081a20 100644
> --- a/drivers/slimbus/qcom-ctrl.c
> +++ b/drivers/slimbus/qcom-ctrl.c
> @@ -695,7 +695,6 @@ static int qcom_slim_resume(struct device *dev)
>  		dev_dbg(dev, "system resume");
>  		ret = qcom_slim_runtime_resume(dev);
>  		if (!ret) {
> -			pm_runtime_mark_last_busy(dev);
>  			pm_request_autosuspend(dev);
>  		}
>  		return ret;


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: (subset) [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls
  2025-07-04  7:54 ` [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls Sakari Ailus
  2025-07-07  8:47   ` Charles Keepax
@ 2025-07-23  8:42   ` Lee Jones
  1 sibling, 0 replies; 21+ messages in thread
From: Lee Jones @ 2025-07-23  8:42 UTC (permalink / raw)
  To: Lee Jones, James Ogletree, Fred Treven, Ben Bright, David Rhodes,
	Richard Fitzgerald, Sakari Ailus
  Cc: patches, linux-kernel, linux-sound

On Fri, 04 Jul 2025 10:54:32 +0300, Sakari Ailus wrote:
> pm_runtime_put_autosuspend(), pm_runtime_put_sync_autosuspend(),
> pm_runtime_autosuspend() and pm_request_autosuspend() now include a call
> to pm_runtime_mark_last_busy(). Remove the now-reduntant explicit call to
> pm_runtime_mark_last_busy().
> 
> 

Applied, thanks!

[42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls
        commit: 324db89e720150e9592d26f1c8da84685f68996b

--
Lee Jones [李琼斯]


^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2025-07-23  8:42 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20250704075225.3212486-1-sakari.ailus@linux.intel.com>
2025-07-04  7:54 ` [PATCH 42/80] mfd: Remove redundant pm_runtime_mark_last_busy() calls Sakari Ailus
2025-07-07  8:47   ` Charles Keepax
2025-07-23  8:42   ` (subset) " Lee Jones
2025-07-04  7:54 ` [PATCH 60/80] soundwire: " Sakari Ailus
2025-07-04  7:54 ` [PATCH 59/80] slimbus: " Sakari Ailus
2025-07-09  6:41   ` Srinivas Kandagatla
2025-07-04  7:54 ` [PATCH 69/80] ALSA: hda: " Sakari Ailus
2025-07-04 11:47   ` Takashi Iwai
2025-07-04 11:52     ` Mark Brown
2025-07-04 11:58       ` Takashi Iwai
2025-07-06  8:27         ` Takashi Iwai
2025-07-04  7:54 ` [PATCH 70/80] ASoC: atmel: " Sakari Ailus
2025-07-04  7:54 ` [PATCH 71/80] ASoC: codecs: " Sakari Ailus
2025-07-07  9:16   ` Charles Keepax
2025-07-04  7:54 ` [PATCH 72/80] ASoC: Intel: " Sakari Ailus
2025-07-04  7:54 ` [PATCH 73/80] ASoC: component: " Sakari Ailus
2025-07-04  7:54 ` [PATCH 74/80] ASoC: SOF: " Sakari Ailus
2025-07-04  8:26   ` Péter Ujfalusi
2025-07-04  7:55 ` [PATCH 75/80] ALSA: intel_hdmi: " Sakari Ailus
2025-07-04 11:45   ` Takashi Iwai
2025-07-06  8:26     ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox