Commit 601cc04c authored by Dan Carpenter's avatar Dan Carpenter Committed by Mark Brown

ASoC: amd: acp: remove unnecessary NULL check

The list iterator in a list_for_each_entry() loop can never be NULL.
Remove the check and pull the code in a tab.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/e376a712-e0c6-446f-9e0b-c444dd795cbb@moroto.mountainSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent dc29d3d2
......@@ -283,7 +283,6 @@ static int __maybe_unused acp63_pcm_resume(struct device *dev)
spin_lock(&adata->acp_lock);
list_for_each_entry(stream, &adata->stream_list, list) {
if (stream) {
substream = stream->substream;
if (substream && substream->runtime) {
buf_in_frames = (substream->runtime->buffer_size);
......@@ -296,7 +295,6 @@ static int __maybe_unused acp63_pcm_resume(struct device *dev)
restore_acp_pdm_params(substream, adata);
}
}
}
spin_unlock(&adata->acp_lock);
return 0;
}
......
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