From: Takashi Iwai Subject: Re: [PATCH] ASoC: Fix another cs4270 error path Date: Mon, 29 Sep 2008 12:58:20 +0200 Message-ID: References: <20080927203052.2a9ed6a1@hyperion.delvare> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id D1A79243E6 for ; Mon, 29 Sep 2008 12:58:20 +0200 (CEST) In-Reply-To: <20080927203052.2a9ed6a1@hyperion.delvare> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Jean Delvare Cc: alsa-devel@alsa-project.org, Mark Brown , Liam Girdwood , Timur Tabi List-Id: alsa-devel@alsa-project.org At Sat, 27 Sep 2008 20:30:52 +0200, Jean Delvare wrote: > > Conversion to new-style i2c driver missed the error path of the > probe function. Fix it. > > Signed-off-by: Jean Delvare > Cc: Timur Tabi Thanks, I'll push it together with Timur's original i2c-conversion patch. Takashi > --- > sound/soc/codecs/cs4270.c | 7 +------ > 1 file changed, 1 insertion(+), 6 deletions(-) > > --- linux-2.6.27-rc7.orig/sound/soc/codecs/cs4270.c 2008-09-27 17:45:47.000000000 +0200 > +++ linux-2.6.27-rc7/sound/soc/codecs/cs4270.c 2008-09-27 18:10:52.000000000 +0200 > @@ -610,17 +610,12 @@ static int cs4270_i2c_probe(struct i2c_c > return 0; > > error: > - if (codec->control_data) { > - i2c_detach_client(i2c_client); > - codec->control_data = NULL; > - } > + codec->control_data = NULL; > > kfree(codec->reg_cache); > codec->reg_cache = NULL; > codec->reg_cache_size = 0; > > - kfree(i2c_client); > - > return ret; > } > > > > -- > Jean Delvare > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@alsa-project.org > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel >