From patchwork Thu Nov 18 03:56:37 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 334991 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oAI3utrq004994 for ; Thu, 18 Nov 2010 03:56:55 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752949Ab0KRD4x (ORCPT ); Wed, 17 Nov 2010 22:56:53 -0500 Received: from mail-wy0-f174.google.com ([74.125.82.174]:47511 "EHLO mail-wy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751532Ab0KRD4w (ORCPT ); Wed, 17 Nov 2010 22:56:52 -0500 Received: by wyb28 with SMTP id 28so2766129wyb.19 for ; Wed, 17 Nov 2010 19:56:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:mime-version:content-type:content-disposition:user-agent; bh=+l3fLIfasq0U/6p8LeKzwREzRHqZTjl0F5pCleH+9UY=; b=I/WZg1Uw6U6Drz61oKf2fjEPhxbIezbiL2+OXupc1js5klEG+bbAE6YvXtW1L+nFEM WDKOm9YQXsNLbhZSFMzCjV9zEF8Y53knvOks4P4Q17Zv4futSEDm6GWZ+Tpv1aZbx8Wy 23qD8vUnHT/AO6UefX3+DPzR6LkXRL2jrosqE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:mime-version:content-type :content-disposition:user-agent; b=FldSbGdMgwK0uWCqQLjXoYHtCUZh1MVcbq5/xxBxC/73UDc6Y7SXMTQkO9+OVcEhP2 sDZ3QuyBfWItzngEU3Wj3kCJQeqWgEC2hPmalxHPQu+f/I8ayc3KiJ1TdQEey+fyN4Qr Y6FQdmDvm6WAxR8K4Ey3fh++QMfBo3YZxB2nU= Received: by 10.216.27.20 with SMTP id d20mr41818wea.99.1290052610294; Wed, 17 Nov 2010 19:56:50 -0800 (PST) Received: from bicker (h2db1.n1.ips.mtn.co.ug [41.210.173.177]) by mx.google.com with ESMTPS id x12sm1517886weq.18.2010.11.17.19.56.45 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 17 Nov 2010 19:56:49 -0800 (PST) Date: Thu, 18 Nov 2010 06:56:37 +0300 From: Dan Carpenter To: Mauro Carvalho Chehab Cc: Devin Heitmueller , Sri Devi , Laurent Pinchart , Jarod Wilson , linux-media@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] [media] cx231xx: stray unlock on error path Message-ID: <20101118035637.GL31724@bicker> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Thu, 18 Nov 2010 03:56:55 +0000 (UTC) diff --git a/drivers/media/video/cx231xx/cx231xx-cards.c b/drivers/media/video/cx231xx/cx231xx-cards.c index 56c2d81..b7b905f 100644 --- a/drivers/media/video/cx231xx/cx231xx-cards.c +++ b/drivers/media/video/cx231xx/cx231xx-cards.c @@ -731,16 +731,12 @@ static int cx231xx_init_dev(struct cx231xx **devhandle, struct usb_device *udev, retval = cx231xx_register_analog_devices(dev); if (retval < 0) { cx231xx_release_resources(dev); - goto fail_reg_devices; + return retval; } cx231xx_init_extension(dev); return 0; - -fail_reg_devices: - mutex_unlock(&dev->lock); - return retval; } #if defined(CONFIG_MODULES) && defined(MODULE)