From patchwork Tue Mar 29 03:19:09 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 670542 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 p2T3JU6R018045 for ; Tue, 29 Mar 2011 03:19:32 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755602Ab1C2DTa (ORCPT ); Mon, 28 Mar 2011 23:19:30 -0400 Received: from mail-fx0-f46.google.com ([209.85.161.46]:63913 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932181Ab1C2DT3 (ORCPT ); Mon, 28 Mar 2011 23:19:29 -0400 Received: by fxm17 with SMTP id 17so3161674fxm.19 for ; Mon, 28 Mar 2011 20:19:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:date:from:to:cc:subject:message-id:mime-version :content-type:content-disposition:user-agent; bh=2aun2zLziWF67hrMA3xEdIgY9kwefH149sslCmXUlbk=; b=ciayocyZviDkhUo/yH9A954+PbyfubWavhsZuakmSDF6vV9dcBNIt3/2InK3NWlTXr B+DY+Ibh7a62KX65gjtS1c+Ft7SnU6TN6eYo20nmH7aVv1EwM/BaOCfQFjJ46DXJGRJr m5uPWGXB9GtMS6SzFbFTT7/kN79u8BF82OfgE= 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=nYrJHp1+3wzhfNQjgT7sdRaa5Ax89911xZf1y2sDrXde9dVETVmH3hujopgZFxPau0 lWJ2/DPYVU/5ehzNAiczVzMSqdutc7vgSVY4uel723ANRZUBh8lRsZ76x7ykDt1ugiXf LcYnOuexumYy/2McKhvsVr2r1dGtTzRDoG7Jw= Received: by 10.223.143.12 with SMTP id s12mr5356449fau.121.1301368768197; Mon, 28 Mar 2011 20:19:28 -0700 (PDT) Received: from bicker ([212.49.88.34]) by mx.google.com with ESMTPS id c24sm1753923fak.7.2011.03.28.20.19.21 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 28 Mar 2011 20:19:27 -0700 (PDT) Date: Tue, 29 Mar 2011 06:19:09 +0300 From: Dan Carpenter To: dh09.lee@samsung.com Cc: Richard Purdie , Paul Mundt , linux-fbdev@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] backlight/ld9040.c: testing the wrong variable in ld9040_probe() Message-ID: <20110329031909.GC9856@bicker> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 29 Mar 2011 03:19:32 +0000 (UTC) diff --git a/drivers/video/backlight/ld9040.c b/drivers/video/backlight/ld9040.c index 7281b25..9e81d69 100644 --- a/drivers/video/backlight/ld9040.c +++ b/drivers/video/backlight/ld9040.c @@ -701,8 +701,8 @@ static int ld9040_probe(struct spi_device *spi) bd = backlight_device_register("ld9040-bl", &spi->dev, lcd, &ld9040_backlight_ops, NULL); - if (IS_ERR(ld)) { - ret = PTR_ERR(ld); + if (IS_ERR(bd)) { + ret = PTR_ERR(bd); goto out_free_lcd; }