Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ASoC: amd: acp: delete unnecessary NULL check

The list iterator can't be NULL. Delete the check and pull the code
in one tab.

Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/b0c5b0ca-68da-47e6-a8b0-e0714f0de119@moroto.mountain
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Dan Carpenter and committed by
Mark Brown
c1325a2d 72ab6858

+10 -12
+10 -12
sound/soc/amd/acp/acp-rembrandt.c
··· 266 266 acp6x_master_clock_generate(dev); 267 267 spin_lock(&adata->acp_lock); 268 268 list_for_each_entry(stream, &adata->stream_list, list) { 269 - if (stream) { 270 - substream = stream->substream; 271 - if (substream && substream->runtime) { 272 - buf_in_frames = (substream->runtime->buffer_size); 273 - buf_size = frames_to_bytes(substream->runtime, buf_in_frames); 274 - config_pte_for_stream(adata, stream); 275 - config_acp_dma(adata, stream, buf_size); 276 - if (stream->dai_id) 277 - restore_acp_i2s_params(substream, adata, stream); 278 - else 279 - restore_acp_pdm_params(substream, adata); 280 - } 269 + substream = stream->substream; 270 + if (substream && substream->runtime) { 271 + buf_in_frames = (substream->runtime->buffer_size); 272 + buf_size = frames_to_bytes(substream->runtime, buf_in_frames); 273 + config_pte_for_stream(adata, stream); 274 + config_acp_dma(adata, stream, buf_size); 275 + if (stream->dai_id) 276 + restore_acp_i2s_params(substream, adata, stream); 277 + else 278 + restore_acp_pdm_params(substream, adata); 281 279 } 282 280 } 283 281 spin_unlock(&adata->acp_lock);