From patchwork Mon Jul 10 11:12:46 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 107287 Delivered-To: patch@linaro.org Received: by 10.140.101.44 with SMTP id t41csp3268660qge; Mon, 10 Jul 2017 04:13:40 -0700 (PDT) X-Received: by 10.99.132.198 with SMTP id k189mr14309198pgd.233.1499685220123; Mon, 10 Jul 2017 04:13:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1499685220; cv=none; d=google.com; s=arc-20160816; b=ROYQTTS7U54NI0P0He6iSO81KZR5/vMaMX6xOvaf1hEcs3ql3CkQ3iuYNGWKLG+Oe3 VgTWbpwjsGbap4L1pls74w51hXwtBsYE8nNeGd/L0VytQoy+tZ/dIleCgSUa0BXqze8M /YTC7HsrztQbwKqwUw5Qq7OOf899SCa6Al49cmwiIf5+yxERut2ioiNXl0SX42BF9LUO xfR3+AZhYMfuZT5Bv8mjkm1GWwkVIrkH5pixnVWw4WQvjcTl3WvlzbOOqHAnoXiMLN6k BQaCMO4B3cDnlAA//rgc4TWu5Cgzr0nJ7WQd1uk8hE3HNmInZ19CSXDiOVMdBMG3+D84 3uEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Rhw2Oif1gMNFoz39bj5/Szz1BBTMSXY77LWK7fq2MdQ=; b=WiMcZPKLimX86FeTMHziqndp8WOUo8YIYRMym8HNyExGC3Dil3vNJyrTrz90HFiqvx FTfDT8/xWsyYtzrTLFmmnz0mty82l8HGTwv/33Wy6inaTVonB/knaLoNk6oznqrtBGEU tfv+kiF/Twmz0ZNAQ/2ponfMYniGIZElOniTFC4SQNFkjztZLjvyYoxD6jZeM4rtdA4y fNQKuPgX0OFS4xoMz0GUMEZkskBK4c6OwPKRpZCD9r5iuKxa6E9UGv5RZkPEiPYe9pH2 L/GXMxD2smC6zndUjWTmr/KF4hxo20LveArc3qLJ7W1JNzGJDI98h9Z9C0mChzLWD428 nXyw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-fbdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-fbdev-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u63si7793269pgb.383.2017.07.10.04.13.40; Mon, 10 Jul 2017 04:13:40 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-fbdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-fbdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-fbdev-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753286AbdGJLNj (ORCPT + 2 others); Mon, 10 Jul 2017 07:13:39 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:49381 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752731AbdGJLNi (ORCPT ); Mon, 10 Jul 2017 07:13:38 -0400 Received: from wuerfel.lan ([5.56.224.194]) by mrelayeu.kundenserver.de (mreue101 [212.227.15.145]) with ESMTPA (Nemesis) id 0Lu5Go-1dduqT3m9G-011Pj1; Mon, 10 Jul 2017 13:13:15 +0200 From: Arnd Bergmann To: Bartlomiej Zolnierkiewicz Cc: Arnd Bergmann , "Gustavo A. R. Silva" , linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] atyfb: hide unused variable Date: Mon, 10 Jul 2017 13:12:46 +0200 Message-Id: <20170710111312.747154-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:WoG9iY82gueF+JpeD90nH5T3mbAt6mlK/NabYT6bP9SmidSOFHK ihrERuODZ0UoSS0JRkYRwSfEkDMnQmUOKi79PCO1n/eCGOz3zZYhWsEgCwpmvVgd3QDuZO+ dB7Xuqb9RlxcUCADONqinaNjbIVAkbVW70D7doDB3Y5bRDR+5v4m5AH7GmmF31m4otoH2dM eyNHfIYOzqOnc0sDt9r6Q== X-UI-Out-Filterresults: notjunk:1; V01:K0:R9e9wXAq6VY=:p3MSjoedGPFCt1fKbDy5ft NgGtQRXjUgPftocyrmt4Fiq35h2BL2Bk6jYd06lPmZXv+Ganak3711ulWSMsUBDQBiPqh65uv B4QTe8x1ZfeQ93Z3zWG3bRoEE/tKvake9SBWgPyv1pG06Aoz9ugdTXCSgijRGhWHUJzUfb1WU QNPeVC/ntXM0fkCEuXNxMx9A6ExsYieMDj+JUKn8jFstRy5W5Ro5s9bZZIf2or0bStDAA58mZ MYWRt1tMnC/SS07JS5/UQPXzn7Z6nb6klZnFTl9PHcd4CdYuLPOEHqZi612T//Fj9/TxT9zxC KMPcQA/0hbz2tV3VAO4rPibHSgCtoAlL8wX3o09JCM+q89/l42M7EYc/5QCspv2P6Fx62v5q4 ALxk5kWLPF4uX/lSMrpOrBiZy3RVLXA1DHNUwwNZc00GtAQsiq3Tm/K/zMkCL7vaCR5p4JIg8 U+6qglSHnANqnUULTYUs1Ce8s+WIlvxXna811dFKB4wlF/gBIlnZ19aXgA7BpZ+EHl8AoKHxq 0tmuI2Gm4VSzeR+kwZkTQpsx0UYKkPf5tWCu1sSTc7h1jsHwGfCSu5ukffAJyAsCX4zwL+/l+ VMnNubU+5mccA+3t8JevwZ7vm2Px06FUVGe/pC1tmywSC3f+qKCaHhB/RHWqvFZMMD2SORx1r kueKSMlPMXv5el7N/GyIZrgUOhmsNQFcru+NVIGFZtxaJs+kqRL4cTFgOPJPWZIC7IDE= Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org The vdisplay variable is now only accessed inside of an #ifdef, producing a harmless warning: drivers/video/fbdev/aty/atyfb_base.c: In function 'aty_var_to_crtc': drivers/video/fbdev/aty/atyfb_base.c:805:19: error: unused variable 'vdisplay' [-Werror=unused-variable] This moves the declaration into the ifdef as well. Fixes: dd7d958ae912 ("video: fbdev: aty: remove useless variable assignments in aty_var_to_crtc()") Signed-off-by: Arnd Bergmann --- drivers/video/fbdev/aty/atyfb_base.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.9.0 -- To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/video/fbdev/aty/atyfb_base.c b/drivers/video/fbdev/aty/atyfb_base.c index ae5535ca3496..18c9b1467197 100644 --- a/drivers/video/fbdev/aty/atyfb_base.c +++ b/drivers/video/fbdev/aty/atyfb_base.c @@ -802,7 +802,7 @@ static int aty_var_to_crtc(const struct fb_info *info, { struct atyfb_par *par = (struct atyfb_par *) info->par; u32 xres, yres, vxres, vyres, xoffset, yoffset, bpp; - u32 sync, vmode, vdisplay; + u32 sync, vmode; u32 h_total, h_disp, h_sync_strt, h_sync_end, h_sync_dly, h_sync_wid, h_sync_pol; u32 v_total, v_disp, v_sync_strt, v_sync_end, v_sync_wid, v_sync_pol, c_sync; u32 pix_width, dp_pix_width, dp_chain_mask; @@ -1030,7 +1030,7 @@ static int aty_var_to_crtc(const struct fb_info *info, crtc->gen_cntl |= CRTC_INTERLACE_EN; #ifdef CONFIG_FB_ATY_GENERIC_LCD if (par->lcd_table != 0) { - vdisplay = yres; + u32 vdisplay = yres; if (vmode & FB_VMODE_DOUBLE) vdisplay <<= 1; crtc->gen_cntl &= ~(CRTC2_EN | CRTC2_PIX_WIDTH);