From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S936303AbcISH2Q (ORCPT ); Mon, 19 Sep 2016 03:28:16 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:7752 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1757915AbcISH1y (ORCPT ); Mon, 19 Sep 2016 03:27:54 -0400 Subject: Re: [PATCH -next] ASoC: sti: fix missing clk_disable_unprepare() on error in uni_player_start() To: Wei Yongjun , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Moise GERGAUD References: <1474076073-9569-1-git-send-email-weiyj.lk@gmail.com> CC: Wei Yongjun , "alsa-devel@alsa-project.org" , "linux-kernel@vger.kernel.org" From: Arnaud Pouliquen X-Enigmail-Draft-Status: N1110 Message-ID: <357834f2-bae9-c481-785e-b5d4dd6f152b@st.com> Date: Mon, 19 Sep 2016 09:27:03 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <1474076073-9569-1-git-send-email-weiyj.lk@gmail.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.201.23.162] X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-09-19_04:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Wei, Acked-by: Arnaud Pouliquen Thanks! On 09/17/2016 03:34 AM, Wei Yongjun wrote: > From: Wei Yongjun > > Fix the missing clk_disable_unprepare() before return > from uni_player_start() in the error handling case. > > Signed-off-by: Wei Yongjun > --- > sound/soc/sti/uniperif_player.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/sound/soc/sti/uniperif_player.c b/sound/soc/sti/uniperif_player.c > index 645e415..1bc8ebc 100644 > --- a/sound/soc/sti/uniperif_player.c > +++ b/sound/soc/sti/uniperif_player.c > @@ -893,8 +893,10 @@ static int uni_player_start(struct uniperif *player) > SET_UNIPERIF_SOFT_RST_SOFT_RST(player); > > ret = reset_player(player); > - if (ret < 0) > + if (ret < 0) { > + clk_disable_unprepare(player->clk); > return ret; > + } > > /* > * Does not use IEC61937 features of the uniperipheral hardware. >