From patchwork Sat Jul 5 12:47:29 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rickard Strandqvist X-Patchwork-Id: 4488201 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A5F66BEEAA for ; Sat, 5 Jul 2014 12:46:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D6D5D20265 for ; Sat, 5 Jul 2014 12:46:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C45E72021F for ; Sat, 5 Jul 2014 12:46:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753889AbaGEMqO (ORCPT ); Sat, 5 Jul 2014 08:46:14 -0400 Received: from mail-we0-f169.google.com ([74.125.82.169]:63453 "EHLO mail-we0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752703AbaGEMqN (ORCPT ); Sat, 5 Jul 2014 08:46:13 -0400 Received: by mail-we0-f169.google.com with SMTP id t60so2574618wes.28 for ; Sat, 05 Jul 2014 05:46:12 -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=PElXCq8Hpx4uP4ENbDVqtHuYwHgJWRMvX4jzYfncaT0=; b=IxDNhUga2/L1Bnrntn3wZmms+fztm86AISlRPGyT8z/cbOL1B3qipJWv5M5YaVdbQH DJok8aHXsg5RztG1hBDcfv9IyhDZVvqETw1DUoSA4nZtw9IWxp5ByNcP/SVFTckbQeTr cBpogjJqFCQWwgbPRL4radu72ui2aJsi4jF6a2RMFby1YkMIgyHe8Kcqr45XXwFwYB9N ibZP24HKV9BUnHLnPtAU/NHoC2ULaDWxs5N0chiS/REuYbAmNvrLQ9OV5hkUGeujsOkw hisfPWZn87kXT0RnAUVdPuPtJO+JWNw+qZKriu9pfDriuIoNJPvs6iUViPKmBNpZh1VD hmNw== X-Gm-Message-State: ALoCoQmjQA4IKQDpGpjgzlXjqAWSPLx0LtF0GZrh9jrcqY1mMnSBbl1NMbTmo5XhcIXNeqkmZLFB X-Received: by 10.180.10.168 with SMTP id j8mr64145057wib.73.1404564372434; Sat, 05 Jul 2014 05:46:12 -0700 (PDT) Received: from localhost.localdomain (h-245-62.a218.priv.bahnhof.se. [85.24.245.62]) by mx.google.com with ESMTPSA id kp5sm75560171wjb.30.2014.07.05.05.46.10 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 05 Jul 2014 05:46:11 -0700 (PDT) From: Rickard Strandqvist To: Jean-Christophe Plagniol-Villard , Tomi Valkeinen Cc: Rickard Strandqvist , Rickard Strandqvist , Jingoo Han , Laurent Pinchart , Rob Clark , Daniel Vetter , linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] video: fbdev: savage: savagefb_driver.c: Cleaning up variable that is never used Date: Sat, 5 Jul 2014 14:47:29 +0200 Message-Id: <1404564449-21633-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/savage/savagefb_driver.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/video/fbdev/savage/savagefb_driver.c b/drivers/video/fbdev/savage/savagefb_driver.c index 4dbf45f..5c7620e 100644 --- a/drivers/video/fbdev/savage/savagefb_driver.c +++ b/drivers/video/fbdev/savage/savagefb_driver.c @@ -951,8 +951,6 @@ static int savagefb_check_var(struct fb_var_screeninfo *var, if (memlen > vramlen) { var->yres_virtual = vramlen * 8 / (var->xres_virtual * var->bits_per_pixel); - memlen = var->xres_virtual * var->bits_per_pixel * - var->yres_virtual / 8; } /* we must round yres/xres down, we already rounded y/xres_virtual up