ASoC: rockchip: Explain DAI link startup return value handling

Add comments explaining why the .startup() callbacks must return
0 on success to ensure the DAI link is correctly marked as started
and prevent future changes from reintroducing the issue.

Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
Link: https://patch.msgid.link/20261016040946.521195-12-phucduc.bui@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
bui duc phuc 2026-10-16 11:09:46 +07:00 committed by Mark Brown
parent a0b64de6ea
commit 48ed45aa30
2 changed files with 10 additions and 0 deletions

View File

@ -266,6 +266,11 @@ static int rockchip_sound_startup(struct snd_pcm_substream *substream)
if (ret < 0)
return ret;
/*
* ASoC only marks the DAI link as started when .startup() returns 0.
* Since snd_pcm_hw_constraint_minmax() may return 1, explicitly
* return 0 to ensure the DAI link is correctly marked as started.
*/
return 0;
}

View File

@ -202,6 +202,11 @@ static int rk_aif1_startup(struct snd_pcm_substream *substream)
if (ret < 0)
return ret;
/*
* ASoC only marks the DAI link as started when .startup() returns 0.
* Since snd_pcm_hw_constraint_minmax() may return 1, explicitly
* return 0 to ensure the DAI link is correctly marked as started.
*/
return 0;
}