From patchwork Fri Mar 8 19:31:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Devendra Naga X-Patchwork-Id: 2240161 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 8AB834006E for ; Fri, 8 Mar 2013 19:31:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751580Ab3CHTbV (ORCPT ); Fri, 8 Mar 2013 14:31:21 -0500 Received: from mail-pb0-f47.google.com ([209.85.160.47]:64827 "EHLO mail-pb0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750851Ab3CHTbV (ORCPT ); Fri, 8 Mar 2013 14:31:21 -0500 Received: by mail-pb0-f47.google.com with SMTP id rp2so1507086pbb.34 for ; Fri, 08 Mar 2013 11:31:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:mime-version :content-type:content-transfer-encoding; bh=SIHE88gEFfKdbfoEONabW7lEToWOz0DKB5blm3QAQxc=; b=gIDZnPc+aMU5vhKNVm0NVFy16krqwXLmtw2vN/+DxHsFXFJGgiyTWLEaYc0gG9agw8 4Ya/JTUKUIO/vP2GBpBhO66h+oTl8grmDyQx2RykCpRsmhNIagPqOvFKZHSA7lN4ifwb MfcPqfGDm0M+rOlLxv0l6UbEO9Vb5PaOQT4gjs47zuvKkBO6NDBmhTngZ036dLknrgHC xlOkDfjN6Wjht7Xcy5qky7iwy2/FctnRjrVlcrKatIbgD2Bolm2tfeZfx20kCsH3oqAP vAMDMG6utIlNegp7sCi07NTQpJGvXx6GnYY9uoRR5MLXjMQRh9qpjzYZ4470lWc8I4Jm T3FQ== X-Received: by 10.68.88.67 with SMTP id be3mr5009068pbb.187.1362771080397; Fri, 08 Mar 2013 11:31:20 -0800 (PST) Received: from localhost.localdomain ([122.172.7.150]) by mx.google.com with ESMTPS id b9sm6504220pba.6.2013.03.08.11.31.17 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 08 Mar 2013 11:31:19 -0800 (PST) From: Devendra Naga To: Andrew Morton , Michael Hennerich , Richard Purdie , device-drivers-devel@blackfin.uclinux.org, linux-fbdev@vger.kernel.org Cc: Devendra Naga , Jingoo Han Subject: [PATCH 1/3] video: backlight: adp5520: fix compiler warning in adp5520_show Date: Fri, 8 Mar 2013 14:31:07 -0500 Message-Id: <1362771069-16345-1-git-send-email-devendra.aaru@gmail.com> X-Mailer: git-send-email 1.8.1.2 MIME-Version: 1.0 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org while compiling with make W=1 (gcc gcc (GCC) 4.7.2 20121109 (Red Hat 4.7.2-8)) found the following warning drivers/video/backlight/adp5520_bl.c: In function ‘adp5520_show’: drivers/video/backlight/adp5520_bl.c:146:6: warning: variable ‘error’ set but not used [-Wunused-but-set-variable] fixed by removing the variable Cc: Jingoo Han Cc: Michael Hennerich Cc: Richard Purdie Signed-off-by: Devendra Naga --- drivers/video/backlight/adp5520_bl.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/backlight/adp5520_bl.c b/drivers/video/backlight/adp5520_bl.c index a1e41d4..9f8b20b 100644 --- a/drivers/video/backlight/adp5520_bl.c +++ b/drivers/video/backlight/adp5520_bl.c @@ -143,11 +143,10 @@ static int adp5520_bl_setup(struct backlight_device *bl) static ssize_t adp5520_show(struct device *dev, char *buf, int reg) { struct adp5520_bl *data = dev_get_drvdata(dev); - int error; uint8_t reg_val; mutex_lock(&data->lock); - error = adp5520_read(data->master, reg, ®_val); + adp5520_read(data->master, reg, ®_val); mutex_unlock(&data->lock); return sprintf(buf, "%u\n", reg_val);