forked from Minki/linux
ASoC: Intel: sst: fix a loop timeout in sst_hsw_stream_reset()
In the original code we ended the loop with tries set to -1 instead of zero. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
af03741262
commit
b8af8b1d80
@ -1345,7 +1345,7 @@ int sst_hsw_stream_reset(struct sst_hsw *hsw, struct sst_hsw_stream *stream)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/* wait for pause to complete before we reset the stream */
|
/* wait for pause to complete before we reset the stream */
|
||||||
while (stream->running && tries--)
|
while (stream->running && --tries)
|
||||||
msleep(1);
|
msleep(1);
|
||||||
if (!tries) {
|
if (!tries) {
|
||||||
dev_err(hsw->dev, "error: reset stream %d still running\n",
|
dev_err(hsw->dev, "error: reset stream %d still running\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user