Commit 5bf5d8fc authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by Mark Brown

ASoC: rsnd: fixup forever loop bug on SSI

commit b5b442ab ("ASoC: rsnd: add .irq callback")
added .irq support, and it cares both parent SSI and normal SSI.
But it should care only normal SSI. Otherwise SSI might be
forever loop if SSI is used as both parent SSI and normal SSI
(= 2 users), and if under/over run error happen. Because irq disable
do nothing in such case. This patch solve this issue.
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 26d34b11
...@@ -149,13 +149,12 @@ static int rsnd_ssi_irq(struct rsnd_mod *mod, ...@@ -149,13 +149,12 @@ static int rsnd_ssi_irq(struct rsnd_mod *mod,
struct rsnd_priv *priv, struct rsnd_priv *priv,
int enable) int enable)
{ {
struct rsnd_ssi *ssi = rsnd_mod_to_ssi(mod);
u32 val = 0; u32 val = 0;
if (rsnd_is_gen1(priv)) if (rsnd_is_gen1(priv))
return 0; return 0;
if (ssi->usrcnt != 1) if (rsnd_ssi_is_parent(mod, io))
return 0; return 0;
if (enable) if (enable)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment