public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 6.5] ASoC: cs35l56: Call pm_runtime_dont_use_autosuspend()
@ 2023-10-02 12:50 Richard Fitzgerald
  2023-10-03 14:49 ` Sasha Levin
  0 siblings, 1 reply; 2+ messages in thread
From: Richard Fitzgerald @ 2023-10-02 12:50 UTC (permalink / raw)
  To: stable; +Cc: linux-kernel, alsa-devel, patches, Richard Fitzgerald

commit ec03804552e9a723569e14d2512f36a8e70dc640 upstream

Driver remove() must call pm_runtime_dont_use_autosuspend().

Drivers that call pm_runtime_use_autosuspend() must disable
it in driver remove(). Unfortunately until recently this was
only mentioned in 1 line in a 900+ line document so most
people hadn't noticed this. It has only recently been added
to the kerneldoc of pm_runtime_use_autosuspend().

Backport note: This is the same change as the upstream
commit but the cs35l56->base.dev argument in the upstream
code is cs35l56->dev in older releases.

Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20230908101716.2658582-1-rf@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
---
Please apply to 6.5.
---
 sound/soc/codecs/cs35l56.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/codecs/cs35l56.c b/sound/soc/codecs/cs35l56.c
index fd06b9f9d496..7e241908b5f1 100644
--- a/sound/soc/codecs/cs35l56.c
+++ b/sound/soc/codecs/cs35l56.c
@@ -1594,6 +1594,7 @@ void cs35l56_remove(struct cs35l56_private *cs35l56)
 	flush_workqueue(cs35l56->dsp_wq);
 	destroy_workqueue(cs35l56->dsp_wq);
 
+	pm_runtime_dont_use_autosuspend(cs35l56->dev);
 	pm_runtime_suspend(cs35l56->dev);
 	pm_runtime_disable(cs35l56->dev);
 
-- 
2.30.2


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

* Re: [PATCH 6.5] ASoC: cs35l56: Call pm_runtime_dont_use_autosuspend()
  2023-10-02 12:50 [PATCH 6.5] ASoC: cs35l56: Call pm_runtime_dont_use_autosuspend() Richard Fitzgerald
@ 2023-10-03 14:49 ` Sasha Levin
  0 siblings, 0 replies; 2+ messages in thread
From: Sasha Levin @ 2023-10-03 14:49 UTC (permalink / raw)
  To: Richard Fitzgerald; +Cc: stable, linux-kernel, alsa-devel, patches

On Mon, Oct 02, 2023 at 01:50:59PM +0100, Richard Fitzgerald wrote:
>commit ec03804552e9a723569e14d2512f36a8e70dc640 upstream
>
>Driver remove() must call pm_runtime_dont_use_autosuspend().
>
>Drivers that call pm_runtime_use_autosuspend() must disable
>it in driver remove(). Unfortunately until recently this was
>only mentioned in 1 line in a 900+ line document so most
>people hadn't noticed this. It has only recently been added
>to the kerneldoc of pm_runtime_use_autosuspend().
>
>Backport note: This is the same change as the upstream
>commit but the cs35l56->base.dev argument in the upstream
>code is cs35l56->dev in older releases.

Queued up, thanks!

-- 
Thanks,
Sasha

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

end of thread, other threads:[~2023-10-03 14:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-02 12:50 [PATCH 6.5] ASoC: cs35l56: Call pm_runtime_dont_use_autosuspend() Richard Fitzgerald
2023-10-03 14:49 ` Sasha Levin

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