Skip to content
Snippets Groups Projects
Commit 528a82b4 authored by Sonny Rao's avatar Sonny Rao Committed by Mark Brown
Browse files

ASoC: rockchip-i2s: fix infinite loop in rockchip_snd_txctrl


We can get into an infinite loop if the I2S_CLR register fails to
clear due to a missing break statement, so add that.

Signed-off-by: default avatarSonny Rao <sonnyrao@chromium.org>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent a5448c88
No related branches found
No related tags found
No related merge requests found
......@@ -108,8 +108,10 @@ static void rockchip_snd_txctrl(struct rk_i2s_dev *i2s, int on)
while (val) {
regmap_read(i2s->regmap, I2S_CLR, &val);
retry--;
if (!retry)
if (!retry) {
dev_warn(i2s->dev, "fail to clear\n");
break;
}
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment