From patchwork Sun Nov 8 08:01:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alex Shi X-Patchwork-Id: 320896 Delivered-To: patch@linaro.org Received: by 2002:a92:7b12:0:0:0:0:0 with SMTP id w18csp880557ilc; Sun, 8 Nov 2020 00:02:12 -0800 (PST) X-Google-Smtp-Source: ABdhPJznVjTACHs4MNNV1SkuhCFt8tBhFLcpW+AoDFBv+nA5oeMUgpaefnajyQHXRhgNnj5d1PJh X-Received: by 2002:a17:906:7704:: with SMTP id q4mr9547830ejm.92.1604822532674; Sun, 08 Nov 2020 00:02:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604822532; cv=none; d=google.com; s=arc-20160816; b=BQC5GOhCvXADr1thHsBcTFPlDZj8sxx/Ypy7RffV2vd2CNkBrJ0ji2F6RDpH+jAKut JlA8wczDyAp1JO5T2VT+y9m9A5+Ax+r1pkIV9WLVCw5sIiafKOud0YirzQKxVAaRElfD 7OkkTsVOr/w3LHg1Pfj2adyKc+aF6hmiXMo6uZsEMscd1dYlzdPGm+T7IN5KJRi2g8Ag Y1SmOhComCCQmCKdwVwfGCRsqtbCsg7Md5QNZ0sJSnkM91Yq6olYSO5ak/M1hvJ69Vcj WUgUOIpxD7YvUdkkWyVLFZGaiyclrB2kRgnRGsIHFPUroB+xQVWxc8H7DvuKAfxqmMss xauQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from; bh=de2VfB9DmqvsnmzV4tyucHJfZ6QlW+CsjleLZIeZ8t4=; b=K3T6sf6azum4zPHwxYwhiFe5KXHU2tELk5TSbu1YigZUEEgN9tgAO+2aqdE6x0eZ1s Pf0bwOSt5JqMM5AtDA/xTXfX3C8McLkmozrJP/d5yhVC63nV90SCzacUHj6v7WtSIJlj 4/OeCBY6HYKStI3B3qNBh4xDEYEWw4FAPG8mz1dWPMniVdsI/BVTZrIaGOlL4M5/RjEw VW6ZmekTxlPm5wnMTw+QGfd1goclJogGY6vJNNaNwY/Llzhvc4y9apYlsyayp74bHQcQ K1i+qkOk9gb/MwL2GTFHd0WLuypeMTC7tqxYKrQDk1hDo/u/GtW4V4H2oMsouBAvBhSg p5KQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-fbdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-fbdev-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u14si4930279edq.494.2020.11.08.00.02.12 for ; Sun, 08 Nov 2020 00:02:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-fbdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-fbdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-fbdev-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726099AbgKHICG (ORCPT ); Sun, 8 Nov 2020 03:02:06 -0500 Received: from out30-54.freemail.mail.aliyun.com ([115.124.30.54]:44737 "EHLO out30-54.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726062AbgKHICG (ORCPT ); Sun, 8 Nov 2020 03:02:06 -0500 X-Alimail-AntiSpam: AC=PASS; BC=-1|-1; BR=01201311R171e4; CH=green; DM=||false|; DS=||; FP=0|-1|-1|-1|0|-1|-1|-1; HT=e01e04394; MF=alex.shi@linux.alibaba.com; NM=1; PH=DS; RN=4; SR=0; TI=SMTPD_---0UEadUVK_1604822521; Received: from aliy80.localdomain(mailfrom:alex.shi@linux.alibaba.com fp:SMTPD_---0UEadUVK_1604822521) by smtp.aliyun-inc.com(127.0.0.1); Sun, 08 Nov 2020 16:02:01 +0800 From: Alex Shi Cc: Antonino Daplas , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH] video: fbdev: riva: remove some unused varibles Date: Sun, 8 Nov 2020 16:01:59 +0800 Message-Id: <1604822519-65607-1-git-send-email-alex.shi@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 MIME-Version: 1.0 To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org Couple of variables are actually useless, remove them to save some gcc warning: drivers/video/fbdev/riva/riva_hw.c:250:21: warning: variable ‘mlwm’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/riva/riva_hw.c:665:15: warning: variable ‘vraw’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/riva/riva_hw.c:665:9: warning: variable ‘craw’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/riva/riva_hw.c:659:73: warning: variable ‘align’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/riva/riva_hw.c:659:50: warning: variable ‘color_key_enable’ set but not used [-Wunused-but-set-variable] Signed-off-by: Alex Shi Cc: Antonino Daplas Cc: linux-fbdev@vger.kernel.org Cc: dri-devel@lists.freedesktop.org Cc: linux-kernel@vger.kernel.org --- drivers/video/fbdev/riva/riva_hw.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) -- 1.8.3.1 diff --git a/drivers/video/fbdev/riva/riva_hw.c b/drivers/video/fbdev/riva/riva_hw.c index 4168ac464565..bcf9c4b4de31 100644 --- a/drivers/video/fbdev/riva/riva_hw.c +++ b/drivers/video/fbdev/riva/riva_hw.c @@ -247,14 +247,13 @@ static int nv3_iterate(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_arb_i int mburst_size = 32; int mmisses, gmisses, vmisses; int misses; - int vlwm, glwm, mlwm; + int vlwm, glwm; int last, next, cur; int max_gfsize ; long ns; vlwm = 0; glwm = 0; - mlwm = 0; vfsize = 0; gfsize = 0; cur = ainfo->cur; @@ -656,13 +655,12 @@ static char nv3_get_param(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_ar nv4_sim_state *arb ) { - int data, pagemiss, cas,width, video_enable, color_key_enable, bpp, align; + int data, pagemiss, cas,width, video_enable, bpp; int nvclks, mclks, pclks, vpagemiss, crtpagemiss, vbs; int found, mclk_extra, mclk_loop, cbs, m1, p1; int mclk_freq, pclk_freq, nvclk_freq, mp_enable; int us_m, us_n, us_p, video_drain_rate, crtc_drain_rate; int vpm_us, us_video, vlwm, video_fill_us, cpm_us, us_crt,clwm; - int craw, vraw; fifo->valid = 1; pclk_freq = arb->pclk_khz; @@ -672,9 +670,7 @@ static char nv3_get_param(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_ar cas = arb->mem_latency; width = arb->memory_width >> 6; video_enable = arb->enable_video; - color_key_enable = arb->gr_during_vid; bpp = arb->pix_bpp; - align = arb->mem_aligned; mp_enable = arb->enable_mp; clwm = 0; vlwm = 0; @@ -782,8 +778,6 @@ static char nv3_get_param(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_ar mclk_extra--; } } - craw = clwm; - vraw = vlwm; if (clwm < 384) clwm = 384; if (vlwm < 128) vlwm = 128; data = (int)(clwm); @@ -842,7 +836,7 @@ static char nv3_get_param(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_ar nv10_sim_state *arb ) { - int data, pagemiss, cas,width, video_enable, color_key_enable, bpp, align; + int data, pagemiss, cas,width, video_enable, bpp; int nvclks, mclks, pclks, vpagemiss, crtpagemiss, vbs; int nvclk_fill, us_extra; int found, mclk_extra, mclk_loop, cbs, m1; @@ -863,9 +857,7 @@ static char nv3_get_param(nv3_fifo_info *res_info, nv3_sim_state * state, nv3_ar cas = arb->mem_latency; width = arb->memory_width/64; video_enable = arb->enable_video; - color_key_enable = arb->gr_during_vid; bpp = arb->pix_bpp; - align = arb->mem_aligned; mp_enable = arb->enable_mp; clwm = 0; vlwm = 1024;