From: Zhang Qilong Date: Wed, 11 Nov 2020 13:09:20 +0000 (+0800) Subject: ASoC: arizona: Fix a wrong free in wm8997_probe X-Git-Tag: v4.14.213~154 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=524321a0ef36caf0b7a9d3e63812724bc5723ee6;p=users%2Fdwmw2%2Flinux.git ASoC: arizona: Fix a wrong free in wm8997_probe [ Upstream commit 5e7aace13df24ff72511f29c14ebbfe638ef733c ] In the normal path, we should not free the arizona, we should return immediately. It will be free when call remove operation. Fixes: 31833ead95c2c ("ASoC: arizona: Move request of speaker IRQs into bus probe") Reported-by: Richard Fitzgerald Signed-off-by: Zhang Qilong Acked-by: Richard Fitzgerald Link: https://lore.kernel.org/r/20201111130923.220186-2-zhangqilong3@huawei.com Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- diff --git a/sound/soc/codecs/wm8997.c b/sound/soc/codecs/wm8997.c index 49401a8aae64a..19c963801e264 100644 --- a/sound/soc/codecs/wm8997.c +++ b/sound/soc/codecs/wm8997.c @@ -1179,6 +1179,8 @@ static int wm8997_probe(struct platform_device *pdev) goto err_spk_irqs; } + return ret; + err_spk_irqs: arizona_free_spk_irqs(arizona);