summaryrefslogtreecommitdiffstats
path: root/sound/soc/amd/vangogh/acp5x-pcm-dma.c
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2022-03-04 14:12:56 +0100
committerMark Brown <broonie@kernel.org>2022-03-07 16:45:56 +0100
commit468f252930d8fda0e4365b788b4b621fe59c05ce (patch)
tree9af5614ba160507207c1690cb2789c67bca73313 /sound/soc/amd/vangogh/acp5x-pcm-dma.c
parentASoC: cs42l42: Add warnings about DETECT_MODE and PLL_START (diff)
downloadlinux-468f252930d8fda0e4365b788b4b621fe59c05ce.tar.xz
linux-468f252930d8fda0e4365b788b4b621fe59c05ce.zip
ASoC: amd: vg: fix signedness bug in acp5x_audio_probe()
The "adata->i2s_irq" variable is unsigned so the error handling will not work. Fixes: 87d71a128771 ("ASoC: amd: pcm-dma: Use platform_get_irq() to get the interrupt") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/20220304131256.GA28739@kili Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/amd/vangogh/acp5x-pcm-dma.c')
-rw-r--r--sound/soc/amd/vangogh/acp5x-pcm-dma.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sound/soc/amd/vangogh/acp5x-pcm-dma.c b/sound/soc/amd/vangogh/acp5x-pcm-dma.c
index e4e668593b3d..31fa166df98a 100644
--- a/sound/soc/amd/vangogh/acp5x-pcm-dma.c
+++ b/sound/soc/amd/vangogh/acp5x-pcm-dma.c
@@ -388,9 +388,10 @@ static int acp5x_audio_probe(struct platform_device *pdev)
if (!adata->acp5x_base)
return -ENOMEM;
- adata->i2s_irq = platform_get_irq(pdev, 0);
- if (adata->i2s_irq < 0)
- return -ENODEV;
+ status = platform_get_irq(pdev, 0);
+ if (status < 0)
+ return status;
+ adata->i2s_irq = status;
dev_set_drvdata(&pdev->dev, adata);
status = devm_snd_soc_register_component(&pdev->dev,