From patchwork Sun Jul 6 18:34:12 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rickard Strandqvist X-Patchwork-Id: 4490911 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 25F319F36A for ; Sun, 6 Jul 2014 18:33:00 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 505CF2022D for ; Sun, 6 Jul 2014 18:32:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4A4FB20219 for ; Sun, 6 Jul 2014 18:32:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752404AbaGFSc5 (ORCPT ); Sun, 6 Jul 2014 14:32:57 -0400 Received: from mail-we0-f173.google.com ([74.125.82.173]:48206 "EHLO mail-we0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752400AbaGFSc5 (ORCPT ); Sun, 6 Jul 2014 14:32:57 -0400 Received: by mail-we0-f173.google.com with SMTP id t60so3458242wes.4 for ; Sun, 06 Jul 2014 11:32:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=DsJ3bT7BccIg72oGMW4wcIVpyQJ6kcs82CtKwQNgxrY=; b=ZqNrRfjy1+E2+XJ8h8zhy7Wy5QWKtFKXAtZrUG7socypF0mr6/MNcX3B95LA4wm/5g BrSWfIWgQ3rbvMUIyBy+NTj6aYh12ZagteMbY7Zu7nmwD1DWaGewZz40kRLCNjlnVtcW 34L1fjfcDXa9lxkQ7buEjz1JzJVSgDZABdtarQE+N+DJm6q8BWudOSijFJUSaYJzOS5b OyQSnlO3bcJrfQwc3q1Xv+fVSirxN5aDDAzr1ncFhdIJM3scQBkO9PbwR9sDwU1E6DhH QGDE6OgYTtriemXD4zU1fs9rBrjk25eiVbJZkSdrNp41I4JHiTeeUM59gtdELMojBXM1 4Pdg== X-Gm-Message-State: ALoCoQnlk9nyru7YMWk+sWPBJYUbNUzdKgfznplaUcKN6V0ephsPmq4D2EQM/A0GyVlzGlfIiNwk X-Received: by 10.180.221.108 with SMTP id qd12mr31600561wic.83.1404671575971; Sun, 06 Jul 2014 11:32:55 -0700 (PDT) Received: from localhost.localdomain (h-245-62.a218.priv.bahnhof.se. [85.24.245.62]) by mx.google.com with ESMTPSA id bx2sm84038632wjb.47.2014.07.06.11.32.54 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 06 Jul 2014 11:32:55 -0700 (PDT) From: Rickard Strandqvist To: Jean-Christophe Plagniol-Villard , Tomi Valkeinen Cc: Rickard Strandqvist , Jingoo Han , Laurent Pinchart , Rob Clark , linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] video: fbdev: intelfb: intelfb_i2c.c: Cleaning up variable that is never used Date: Sun, 6 Jul 2014 20:34:12 +0200 Message-Id: <1404671652-18374-1-git-send-email-rickard_strandqvist@spectrumdigital.se> X-Mailer: git-send-email 1.7.10.4 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Variable ar assigned a value that is never used. I have also removed all the code that thereby serves no purpose. This was found using a static code analysis program called cppcheck Signed-off-by: Rickard Strandqvist --- drivers/video/fbdev/intelfb/intelfb_i2c.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/video/fbdev/intelfb/intelfb_i2c.c b/drivers/video/fbdev/intelfb/intelfb_i2c.c index 3300bd3..4df2f1f 100644 --- a/drivers/video/fbdev/intelfb/intelfb_i2c.c +++ b/drivers/video/fbdev/intelfb/intelfb_i2c.c @@ -55,22 +55,20 @@ static void intelfb_gpio_setscl(void *data, int state) { struct intelfb_i2c_chan *chan = data; struct intelfb_info *dinfo = chan->dinfo; - u32 val; OUTREG(chan->reg, (state ? SCL_VAL_OUT : 0) | SCL_DIR | SCL_DIR_MASK | SCL_VAL_MASK); - val = INREG(chan->reg); + INREG(chan->reg); } static void intelfb_gpio_setsda(void *data, int state) { struct intelfb_i2c_chan *chan = data; struct intelfb_info *dinfo = chan->dinfo; - u32 val; OUTREG(chan->reg, (state ? SDA_VAL_OUT : 0) | SDA_DIR | SDA_DIR_MASK | SDA_VAL_MASK); - val = INREG(chan->reg); + INREG(chan->reg); } static int intelfb_gpio_getscl(void *data)