From patchwork Wed May 5 05:59:48 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 96985 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o45608DU028043 for ; Wed, 5 May 2010 06:00:08 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754657Ab0EEGAG (ORCPT ); Wed, 5 May 2010 02:00:06 -0400 Received: from mail-fx0-f46.google.com ([209.85.161.46]:64880 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752789Ab0EEGAE (ORCPT ); Wed, 5 May 2010 02:00:04 -0400 Received: by fxm10 with SMTP id 10so3900400fxm.19 for ; Tue, 04 May 2010 23:00:02 -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=8hYBY8d39aF6htSAhg9/0xCHSTs48yQSOp1kU6N3mLM=; b=rZ8VD9vGwbjE7jEGDWPxTLz/42DFsjFblVAwxzzMuNyYNLPi9/ItcAaYy/mf07+FlO FQp9NmeF4TfNLAfQy5+QeS12sqUEJqaKIZhTpZpobzuWMo4Lf22h19iuEJhxPRaA6tk7 I7gXAORr1vvZnGVYpbeOFR3DZoU/uTeppIEA0= 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=ak/63rNRx8MRgfNADNI3jz6o1/SE5aqfWsjZ+BjR6hBT69f444Si2oeoxiYJRNpq4o oQ0DAq6yoZS3/EZwN8oeofbW6GCDMaKaGGIDsLv2Xf6zA/tsQUDQFCi+ZyWca+E5PHln S0tdzsGimMNKMZVE3xQxNA5/8RNpJYsinudVA= Received: by 10.223.21.23 with SMTP id h23mr4988949fab.21.1273039202697; Tue, 04 May 2010 23:00:02 -0700 (PDT) Received: from bicker ([205.177.176.130]) by mx.google.com with ESMTPS id 21sm12838990fkx.10.2010.05.04.23.00.00 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 04 May 2010 23:00:02 -0700 (PDT) Date: Wed, 5 May 2010 07:59:48 +0200 From: Dan Carpenter To: linux-media@vger.kernel.org Cc: Mauro Carvalho Chehab Subject: [patch] media/ov511: cleanup: remove unneeded null check Message-ID: <20100505055948.GE27064@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]); Wed, 05 May 2010 06:00:09 +0000 (UTC) diff --git a/drivers/media/video/ov511.c b/drivers/media/video/ov511.c index 6085d55..a109120 100644 --- a/drivers/media/video/ov511.c +++ b/drivers/media/video/ov511.c @@ -5940,7 +5940,7 @@ ov51x_disconnect(struct usb_interface *intf) ov->dev = NULL; /* Free the memory */ - if (ov && !ov->user) { + if (!ov->user) { mutex_lock(&ov->cbuf_lock); kfree(ov->cbuf); ov->cbuf = NULL;