mirror of
https://github.com/torvalds/linux.git
synced 2024-12-27 05:11:48 +00:00
ASoC: AMD: free memory on error
Static checkers complain if we don't free "adata" before returning.
Fixes: 7c31335a03
('ASoC: AMD: add AMD ASoC ACP 2.x DMA driver')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
7cb1dc8109
commit
cde6bcd584
@ -635,6 +635,7 @@ static int acp_dma_open(struct snd_pcm_substream *substream)
|
||||
SNDRV_PCM_HW_PARAM_PERIODS);
|
||||
if (ret < 0) {
|
||||
dev_err(prtd->platform->dev, "set integer constraint failed\n");
|
||||
kfree(adata);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user