From patchwork Thu Aug 12 07:41:58 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 119205 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7C7gspF024272 for ; Thu, 12 Aug 2010 07:42:55 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754187Ab0HLHmw (ORCPT ); Thu, 12 Aug 2010 03:42:52 -0400 Received: from mail-wy0-f174.google.com ([74.125.82.174]:62291 "EHLO mail-wy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752693Ab0HLHmv (ORCPT ); Thu, 12 Aug 2010 03:42:51 -0400 Received: by wyb32 with SMTP id 32so1079156wyb.19 for ; Thu, 12 Aug 2010 00:42:49 -0700 (PDT) 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=lpWQPlTtcAa6fCNxbwp0xn+GUCM2HaY6L0Ad9G7Kt44=; b=EGYklztIfeKgPYLpO+4NPJISr6JeEgE9eHjrMH2ntTUZmu5qJos5TodmgTCLFYwE8X IZuJeXcbdWizTcwUSVlz1b5P6IhXF/o9Dm44I775Igz2YwuXZ9MAcEF6Qzj4tM42VBDr OklCEELQa1ZEjsNWFZrQXJKCCp+hHFIbIv8i4= 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=iT9nf/azw/GWK0HEBrHFGhMHNScA2k5hmRBav9K19bsYZszd/o9TddSCiPydjal0vq 7I9xUwAZ9XBxx0n9uOhL2c0Ql9+ubI/Lj7zuuGW5vp0lCFLn7MGaRM4OK4vFcIBsZLqj Lqk3llezHJ4rLvbEJuqXt84Bv3wm8dHb2yr+c= Received: by 10.227.37.8 with SMTP id v8mr17290333wbd.37.1281598969763; Thu, 12 Aug 2010 00:42:49 -0700 (PDT) Received: from bicker ([205.177.176.130]) by mx.google.com with ESMTPS id e31sm953508wbe.5.2010.08.12.00.42.18 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 12 Aug 2010 00:42:49 -0700 (PDT) Date: Thu, 12 Aug 2010 09:41:58 +0200 From: Dan Carpenter To: Mauro Carvalho Chehab Cc: Pawel Osciak , Kyungmin Park , Sylwester Nawrocki , linux-media@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] V4L/DVB: unlock on error path Message-ID: <20100812074158.GH645@bicker> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) 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 (demeter.kernel.org [140.211.167.41]); Thu, 12 Aug 2010 07:42:55 +0000 (UTC) diff --git a/drivers/media/video/s5p-fimc/fimc-core.c b/drivers/media/video/s5p-fimc/fimc-core.c index b151c7b..1beb226 100644 --- a/drivers/media/video/s5p-fimc/fimc-core.c +++ b/drivers/media/video/s5p-fimc/fimc-core.c @@ -822,7 +822,8 @@ static int fimc_m2m_s_fmt(struct file *file, void *priv, struct v4l2_format *f) } else { v4l2_err(&ctx->fimc_dev->m2m.v4l2_dev, "Wrong buffer/video queue type (%d)\n", f->type); - return -EINVAL; + ret = -EINVAL; + goto s_fmt_out; } pix = &f->fmt.pix;