[PATCH 09/24] ASoC: atmel: atmel-pcm-pdc: Fix atmel_pcm_close() being skipped on rollback
phucduc.bui at gmail.com
phucduc.bui at gmail.com
Thu Oct 8 03:38:16 PDT 2026
From: bui duc phuc <phucduc.bui at gmail.com>
snd_pcm_hw_constraint_integer() may return 1, which is then returned
from atmel_pcm_open(). ASoC only marks the component as opened
when .open() returns 0, so .close() can be skipped on rollback.
Return 0 explicitly on success.
Fixes: 92dfa6198623 ("ASoC: atmel-pcm: split into two file")
Signed-off-by: bui duc phuc <phucduc.bui at gmail.com>
---
sound/soc/atmel/atmel-pcm-pdc.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sound/soc/atmel/atmel-pcm-pdc.c b/sound/soc/atmel/atmel-pcm-pdc.c
index 374f93fa6e0b..552bfa30d4ba 100644
--- a/sound/soc/atmel/atmel-pcm-pdc.c
+++ b/sound/soc/atmel/atmel-pcm-pdc.c
@@ -295,6 +295,8 @@ static int atmel_pcm_open(struct snd_soc_component *component,
}
runtime->private_data = prtd;
+ return 0;
+
out:
return ret;
}
--
2.43.0
More information about the Linux-rockchip
mailing list