Thread (13 messages) 13 messages, 2 authors, 2d ago

[PATCH 06/11] ASoC: intel: atom: Explain DAI startup return value handling

flat view
WARM2d REVIEWED: 1 (1M)

From: <hidden>
Date: 2026-10-16 04:11:26
Also in: asahi, imx, linux-renesas-soc, linux-rockchip, linux-sound, lkml
Subsystem: intel asoc drivers, sound, sound - soc layer / dynamic audio power management (asoc), the rest · Maintainers: Cezary Rojewski, Liam Girdwood, Peter Ujfalusi, Bard Liao, Kai Vehmanen, Jaroslav Kysela, Takashi Iwai, Liam Girdwood, Mark Brown, Linus Torvalds

1 review trailer (1 from subsystem maintainers).

From: bui duc phuc <redacted>

Add a comment explaining why .startup() must return 0 on success
to ensure proper rollback handling and prevent future changes
from reintroducing the issue.

Acked-by: Cezary Rojewski <cezary.rojewski@intel.com>
Signed-off-by: bui duc phuc <redacted>
---
 sound/soc/intel/atom/sst-mfld-platform-pcm.c | 5 +++++
 1 file changed, 5 insertions(+)
diff --git a/sound/soc/intel/atom/sst-mfld-platform-pcm.c b/sound/soc/intel/atom/sst-mfld-platform-pcm.c
index db1fb3b26909..58681e007abf 100644
--- a/sound/soc/intel/atom/sst-mfld-platform-pcm.c
+++ b/sound/soc/intel/atom/sst-mfld-platform-pcm.c
@@ -341,6 +341,11 @@ static int sst_media_open(struct snd_pcm_substream *substream,
 
 	stream = NULL;
 
+	/*
+	 * ASoC only marks the DAI as started when .startup() returns 0.
+	 * Since snd_pcm_hw_constraint_integer() may return 1, explicitly
+	 * return 0 to ensure .shutdown() is not skipped on rollback.
+	 */
 	return 0;
 }
 
-- 
2.43.0

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help