From efd9eb96d5604c2c133e500f7b8c7b3f3fbdece8 Mon Sep 17 00:00:00 2001 From: Manuel Lauss Date: Tue, 1 Dec 2009 18:10:35 +0100 Subject: [PATCH] ASoC: au1x: dbdma2: plug memleak in pcm device creation error path free the allocated pcm platform device in the error path. Signed-off-by: Manuel Lauss Acked-by: Liam Girdwood Signed-off-by: Mark Brown --- sound/soc/au1x/dbdma2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/soc/au1x/dbdma2.c b/sound/soc/au1x/dbdma2.c index 2ca33b09a86..19e4d37eba1 100644 --- a/sound/soc/au1x/dbdma2.c +++ b/sound/soc/au1x/dbdma2.c @@ -480,6 +480,7 @@ struct platform_device *au1xpsc_pcm_add(struct platform_device *pdev) if (!ret) return pd; + platform_device_put(pd); out: kfree(res); return NULL;