From patchwork Fri Aug 6 06:28:49 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 117710 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 o766TGCT019607 for ; Fri, 6 Aug 2010 06:29:16 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753932Ab0HFG3P (ORCPT ); Fri, 6 Aug 2010 02:29:15 -0400 Received: from mail-ww0-f44.google.com ([74.125.82.44]:48915 "EHLO mail-ww0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752900Ab0HFG3O (ORCPT ); Fri, 6 Aug 2010 02:29:14 -0400 Received: by wwj40 with SMTP id 40so8682213wwj.1 for ; Thu, 05 Aug 2010 23:29:13 -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=++C2tGxDPLTs3ObR4ZozKq3d6J/C3qxjy4Dh0m1DInI=; b=C6+S4rimHtVqHCrKm15dLUCfWZdhS+1drWyjNwS77acpGzB0dKtEMNoF8lMO+GCzmL dpX7b+85I7nJ0WjjsVyFn26kp4v+415+nXOeb1dgpMQgMZaUzUe2jA6iy4SyETHwVbDp 77Xvmxx5FXncU28NrmiufTC9DIFYFx5Z/VBwY= 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=WC612xFNdqH+mJy01Y6ZkYSCRwtQdYeNgjNv2JO6pxlfa6CSRKNcZcwRPNNzOywX1a m8hlsbOlJyYHckDrGo2N1iOgsQu1tx0dJoqSeC+Icao1CQCf1zwq/AXIAt/HbTxdUnjC PO8ZJNL+p0fZoZWbp0NCh5GVrmcXcKaMC00mo= Received: by 10.216.2.198 with SMTP id 48mr456203wef.107.1281076152996; Thu, 05 Aug 2010 23:29:12 -0700 (PDT) Received: from bicker ([205.177.176.130]) by mx.google.com with ESMTPS id w29sm627283weq.18.2010.08.05.23.29.05 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 05 Aug 2010 23:29:12 -0700 (PDT) Date: Fri, 6 Aug 2010 08:28:49 +0200 From: Dan Carpenter To: Jiri Kosina Cc: Bruno =?iso-8859-1?Q?Pr=E9mont?= , Jaya Kumar , linux-input@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] hid: picolcd: testing the wrong variable Message-ID: <20100806062848.GL9031@bicker> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@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]); Fri, 06 Aug 2010 06:29:16 +0000 (UTC) diff --git a/drivers/hid/hid-picolcd.c b/drivers/hid/hid-picolcd.c index 346f0e3..c0bdeba 100644 --- a/drivers/hid/hid-picolcd.c +++ b/drivers/hid/hid-picolcd.c @@ -547,7 +547,7 @@ static void picolcd_fb_destroy(struct fb_info *info) ref_cnt--; mutex_lock(&info->lock); (*ref_cnt)--; - may_release = !ref_cnt; + may_release = !*ref_cnt; mutex_unlock(&info->lock); if (may_release) { framebuffer_release(info);