From patchwork Sat Jul 5 12:18:19 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rickard Strandqvist X-Patchwork-Id: 4487581 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 EA5FD9F26C for ; Sat, 5 Jul 2014 12:17:07 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 095F020263 for ; Sat, 5 Jul 2014 12:17:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 30E9520221 for ; Sat, 5 Jul 2014 12:17:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754784AbaGEMRF (ORCPT ); Sat, 5 Jul 2014 08:17:05 -0400 Received: from mail-wi0-f172.google.com ([209.85.212.172]:56060 "EHLO mail-wi0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752951AbaGEMRE (ORCPT ); Sat, 5 Jul 2014 08:17:04 -0400 Received: by mail-wi0-f172.google.com with SMTP id hi2so13991666wib.17 for ; Sat, 05 Jul 2014 05:17:02 -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=OhG6eSrZGAlYvvxIa6E1b07pPaW9I2K+xQ4DhmVezw0=; b=iYlGSZKJc4Vh37MnRlORCSaYBGKA6fV5WyHFEmANQwPwxNvxhcIzN2twxSJm+xyALh MipkFj+0FYlwrM+UOJ2mtP9JtxjVxoyFi0LwrhcBe9peDQCqEtokBulGmkn/wJup/Sy7 Km8GMIislt7SEjTOWSPQeU3IvtJGCr8J05SoNt1sC5yoZU8F6RNc9fQ1FvaflhQmFf6v Nksh8KL9RrO7dK5M92vWdJBM6Ygz+QLiimvMgBMqQhniQJkA49deD2VejI3TiFG8e+br fxVdvvNaj8wTBFbNw0kjWIfFuJziQMrwWlJobM7FyaX59YcOBgk67DwffIZzHktqeeRp CCMQ== X-Gm-Message-State: ALoCoQnMqQ9+X9s1AFDq2YehgS4tqJqRYlX9sb0nI/7nGB5S5wou9Hi2jMojYgodf5btvZdsb1xy X-Received: by 10.180.212.68 with SMTP id ni4mr23858629wic.64.1404562622755; Sat, 05 Jul 2014 05:17:02 -0700 (PDT) Received: from localhost.localdomain (h-245-62.a218.priv.bahnhof.se. [85.24.245.62]) by mx.google.com with ESMTPSA id i4sm90521349wib.21.2014.07.05.05.17.01 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 05 Jul 2014 05:17:02 -0700 (PDT) From: Rickard Strandqvist To: Jean-Christophe Plagniol-Villard , Tomi Valkeinen Cc: Rickard Strandqvist , Rickard Strandqvist , Jingoo Han , Daniel Vetter , Laurent Pinchart , Rob Clark , Hanjun Guo , linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] video: fbdev: au1200fb.c: Cleaning up variable that is never used Date: Sat, 5 Jul 2014 14:18:19 +0200 Message-Id: <1404562699-19171-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=-6.9 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 From: Rickard Strandqvist 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/au1200fb.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/fbdev/au1200fb.c b/drivers/video/fbdev/au1200fb.c index 4cfba78..2249d3d 100644 --- a/drivers/video/fbdev/au1200fb.c +++ b/drivers/video/fbdev/au1200fb.c @@ -710,7 +710,7 @@ static int fbinfo2index (struct fb_info *fb_info) static int au1200_setlocation (struct au1200fb_device *fbdev, int plane, int xpos, int ypos) { - uint32 winctrl0, winctrl1, winenable, fb_offset = 0; + uint32 winctrl0, winctrl1, winenable; int xsz, ysz; /* FIX!!! NOT CHECKING FOR COMPLETE OFFSCREEN YET */ @@ -738,7 +738,6 @@ static int au1200_setlocation (struct au1200fb_device *fbdev, int plane, if (xpos < 0) { /* Off-screen to the left */ xsz = win->w[plane].xres + xpos; - fb_offset += (((0 - xpos) * winbpp(lcd->window[plane].winctrl1))/8); xpos = 0; /*printk("off screen left\n");*/ }