Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp3028698ybg; Sat, 6 Jun 2020 08:33:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwVTBEpPfZtlL3xajexy1ViRcBqRkyqpLLmSy8q/79d4dKUVw//1NatIhwZ/M4YMZEKnxP9 X-Received: by 2002:a17:906:9381:: with SMTP id l1mr14259379ejx.380.1591457591856; Sat, 06 Jun 2020 08:33:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591457591; cv=none; d=google.com; s=arc-20160816; b=MVSha/eeD2E8csoxLn7520bgsNixx86Amykcbym4UaPifC1l1BkyKT+Y8xCHYZ18Z+ vQgG8imKAt+TIAVE7MsXKvAd/7TsuIGf0Ajf0CM4ghTY75Otul4HA4+x/iABn0asEf13 JRaiGdQFwHDZxMLTrAk+FSl3WZhjGVeHkduqUgsj+xRH3m4XsIiHNaF+H0KuSL4C0jUD waf9+Y5ik5FB2MrJFdDHbKhZQoiR/K12Y0go+2HtKWxnkKGBTm6pse27bJcFcSEiFsW0 p3E1VLtzCINGBfELFBckPGMcF/XpgnKdBeNK4VnyjVGnEiYefdDVUB6oA2++mtYdIklw c3EQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:content-disposition :mime-version:message-id:subject:to:from:date; bh=GQAWIUUoU10n2e7TYbVBypzvIPUsXehmG5Aokc2EAT8=; b=uyoN81J+/KJTRWmp7LumdpCDH738/rViVQs5RYrqajYnyecu7IrUOiEq68BqmdKdcq NM9NDlF6++SebHzOnE/j0SHWSYs1YBjzNlLrGRncdkywD9NywyBIGTDqhzVXci2TkAsz ja4Xn7l+8CZeMteJM+RKE9Z6QhByKu91fQ3GIBWJnu4Tswu7jl2rAGt5NB261jR1CfWf U2hpwfEWiFKNPTdnCXLz2nlG7lOC0RWObQr+JoIBtqRoVW8PEUiqfKqsLrBN+rtJPBIy s9hRqtcvKJs2vUuqnRv7uxv1CSMA6pqPsP3sLYWkneXBqRggPglsAyiVzHLYYfVXGsl9 /w3g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r2si5231576edq.185.2020.06.06.08.32.49; Sat, 06 Jun 2020 08:33:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727100AbgFFPbG (ORCPT + 99 others); Sat, 6 Jun 2020 11:31:06 -0400 Received: from jabberwock.ucw.cz ([46.255.230.98]:57820 "EHLO jabberwock.ucw.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726327AbgFFPbG (ORCPT ); Sat, 6 Jun 2020 11:31:06 -0400 Received: by jabberwock.ucw.cz (Postfix, from userid 1017) id CD6821C0BD2; Sat, 6 Jun 2020 17:31:04 +0200 (CEST) Date: Sat, 6 Jun 2020 17:31:03 +0200 From: Pavel Machek To: jbrunet@baylibre.com, lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, khilman@baylibre.com, alsa-devel@alsa-project.org, linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, trivial@kernel.org Subject: [PATCH] soc/meson: add missing free_irq() in error path Message-ID: <20200606153103.GA17905@amd> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="/04w6evG8XlLl3ft" Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --/04w6evG8XlLl3ft Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable free_irq() is missing in case of error, fix that. Signed-off-by: Pavel Machek (CIP) diff --git a/sound/soc/meson/axg-fifo.c b/sound/soc/meson/axg-fifo.c index 2e9b56b29d31..b2e867113226 100644 --- a/sound/soc/meson/axg-fifo.c +++ b/sound/soc/meson/axg-fifo.c @@ -249,7 +249,7 @@ int axg_fifo_pcm_open(struct snd_soc_component *compone= nt, /* Enable pclk to access registers and clock the fifo ip */ ret =3D clk_prepare_enable(fifo->pclk); if (ret) - return ret; + goto free_irq; =20 /* Setup status2 so it reports the memory pointer */ regmap_update_bits(fifo->map, FIFO_CTRL1, @@ -269,8 +269,14 @@ int axg_fifo_pcm_open(struct snd_soc_component *compon= ent, /* Take memory arbitror out of reset */ ret =3D reset_control_deassert(fifo->arb); if (ret) - clk_disable_unprepare(fifo->pclk); + goto free_clk; + + return 0; =20 +free_clk: + clk_disable_unprepare(fifo->pclk); +free_irq: + free_irq(fifo->irq, ss); return ret; } EXPORT_SYMBOL_GPL(axg_fifo_pcm_open); --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --/04w6evG8XlLl3ft Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAl7btrcACgkQMOfwapXb+vJ51wCdFIey2vjfzhnWLuSj7KK518uE 1BgAn3bsVTxHs8pdwxUTDu7T0dLdrWBj =0D1B -----END PGP SIGNATURE----- --/04w6evG8XlLl3ft--