From patchwork Wed Jan 13 14:49:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 362121 Delivered-To: patch@linaro.org Received: by 2002:a02:ccad:0:0:0:0:0 with SMTP id t13csp598062jap; Wed, 13 Jan 2021 06:50:42 -0800 (PST) X-Google-Smtp-Source: ABdhPJzkq3mb2w8gSabCRgU2anHER8e/oyu0YxvPEcJZ7Vic+asmG1n+dCNr1Q7c3TX0zWX5rZEy X-Received: by 2002:a63:c908:: with SMTP id o8mr2377732pgg.124.1610549441927; Wed, 13 Jan 2021 06:50:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610549441; cv=none; d=google.com; s=arc-20160816; b=nGGra1s5OomxtMmIROLeVY9nL4WROiPFgSekeVKg1V/Arr0s3czcPAsmGUxsN91/8q p9nUMtryviYGrLlebKX7+G697AKdhG0UU0Rt+Z4yyreMDHwKoRZ+dPXJRKgajiVE8KUZ hM8s4NTtInCbxLnYydAGY9SHsuTa2ytkOLyIyl04h7RgvIFVTqkwKW/1ZSgKUdGSZUmv g78sQkWgPviY3ZPgf5Rx8B6Sq4VTMizSi3tcINJJFR3TNyMZVXR9HGY8XQsY772c65/2 V2mse72T14IDO5WNXRziKtowJOZsl/9LQc32PY/a8b8RxE0tWyZzYy6p9m+Hj4b55bps kfZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:references:in-reply-to:message-id:date :subject:to:from:dkim-signature:delivered-to; bh=nHtRi31qCoro5f5wEviDJXZWLlKJWdbu+oKne/AXAnk=; b=av7kFlS9LoRe8Fr9GjiZwPZzDr+zoK4r51fJjdmLa2sw9a6SIoIlDGbYTX7/pUw9Lh JUXPRrRZ6dqkZvl1cqOdXwHWuCh7hgkRXPLYP7rfvIVnxtZInXmm40zfzkSzDhSNuqfX /YNAT1XLk75GzyCfFAlTVb6PE3vQJ/uQwIwsWUDdzfCCMsbL5MiEc3xXikmgv3S6/FgE 1/1jEvaQhyp7OPKa7r9WG3o5Xx9vXISGcKZ1nvCss/Ap9rTmGpjMLtNu5TM+u0DueXmH feo0gdO4GA2NUEuttNeJDqogGHijRD6uVuAZEYjrA7Hci3/QVRMgJdgHkRGOp76vhmc8 5cbA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=akpdEhMJ; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id i66si2567028pfe.325.2021.01.13.06.50.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 06:50:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=akpdEhMJ; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E55EE6EA58; Wed, 13 Jan 2021 14:50:34 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by gabe.freedesktop.org (Postfix) with ESMTPS id 89DFA6EA51 for ; Wed, 13 Jan 2021 14:50:32 +0000 (UTC) Received: by mail-wm1-x331.google.com with SMTP id h17so1654152wmq.1 for ; Wed, 13 Jan 2021 06:50:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=UBertLrO50IMon3TZ4gj0CSxI3Yqy8ksl/8MP2cv2iw=; b=akpdEhMJh2ARCHyoNNx9VPJuhAoo9/Y4QVqEYnbUJ0Hy/4xwAFnitREVMt08+c+3Qu Kc2u8TwF4caPKUyn75DQBoHuu3wGDMO0r2V3p0Yo+d9smk9uBH9HBLge1hMCGnifQUR9 JjsszdKmG43arb7E46nkyyLFqd/tXDE7Y7P9jv3oeKYHpCIPG8OOt+aQ4sR1/nWloE2f 51Wwa7J/1t45aqUrswNJxn0kk2k4+oGZ23ac7biP9+idnJfOmRnbqPHH2PwdliX+83OH bnrAP/8D7ucxpARodtDBgI/9O7O5s2Vfm3AXS7vGGur65NmXvY4JTtIa3YxDSPJQGQVk BZgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=UBertLrO50IMon3TZ4gj0CSxI3Yqy8ksl/8MP2cv2iw=; b=AXqxA70rPPA9N+DrzEHa2+g4L0cQ1lKnteuD4VHVb+IYvXgnQOh1tA3AtEfRd10HEv dF5q0Ie/rUDlM/IMcfG3fP4cFfDvq6Uwq03ouEty8jFX8o91pBE3wXxzE3SmPRXqtOEq 74fa+xLVT5y+yAxEIvUDSt9dhMM9crhZf5UIX9l5QX5n2KbqdTfB5MdSnCBI5NMMId/w D9Im+hjqNVhrByt6oQ7qtPwOJpsDJJEcQciQLDjLYnMwGJHSUlVeSiXeiVqtV836tKAL AXVmvtVXRYLahiiWvjBLReirVKWc93aIruFtyK4mwMjvNLpIrDRDYB0ANZyEqDI7wS1p 5UOw== X-Gm-Message-State: AOAM530117+2buHq35+iCZmbkFrw3uhcobj5zGAebt9U25/4e0Sx+dxe u9f429p4UYg6RJiJAtmsP4nrrQ== X-Received: by 2002:a7b:c10e:: with SMTP id w14mr2520321wmi.161.1610549431282; Wed, 13 Jan 2021 06:50:31 -0800 (PST) Received: from dell.default ([91.110.221.229]) by smtp.gmail.com with ESMTPSA id t188sm3273433wmf.9.2021.01.13.06.50.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 06:50:30 -0800 (PST) From: Lee Jones To: lee.jones@linaro.org Subject: [PATCH 11/31] video: fbdev: sis: init: Remove four unused variables Date: Wed, 13 Jan 2021 14:49:49 +0000 Message-Id: <20210113145009.1272040-12-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210113145009.1272040-1-lee.jones@linaro.org> References: <20210113145009.1272040-1-lee.jones@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-fbdev@vger.kernel.org, Thomas Winischhofer , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes the following W=1 kernel build warning(s): drivers/video/fbdev/sis/init.c: In function ‘SiS_SetCRT1ModeRegs’: drivers/video/fbdev/sis/init.c:2651:49: warning: variable ‘resindex’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/sis/init.c: In function ‘SiS_Generic_ConvertCRData’: drivers/video/fbdev/sis/init.c:3544:19: warning: variable ‘A’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/sis/init.c:3542:34: warning: variable ‘VBS’ set but not used [-Wunused-but-set-variable] drivers/video/fbdev/sis/init.c:3541:34: warning: variable ‘HBS’ set but not used [-Wunused-but-set-variable] Cc: Thomas Winischhofer Cc: dri-devel@lists.freedesktop.org Cc: linux-fbdev@vger.kernel.org Signed-off-by: Lee Jones --- drivers/video/fbdev/sis/init.c | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/drivers/video/fbdev/sis/init.c b/drivers/video/fbdev/sis/init.c index fde27feae5d0c..4510272ad297a 100644 --- a/drivers/video/fbdev/sis/init.c +++ b/drivers/video/fbdev/sis/init.c @@ -2648,7 +2648,7 @@ static void SiS_SetCRT1ModeRegs(struct SiS_Private *SiS_Pr, unsigned short ModeNo, unsigned short ModeIdIndex, unsigned short RRTI) { - unsigned short data, infoflag = 0, modeflag, resindex; + unsigned short data, infoflag = 0, modeflag; #ifdef CONFIG_FB_SIS_315 unsigned char *ROMAddr = SiS_Pr->VirtualRomBase; unsigned short data2, data3; @@ -2659,7 +2659,7 @@ SiS_SetCRT1ModeRegs(struct SiS_Private *SiS_Pr, unsigned short ModeNo, if(SiS_Pr->UseCustomMode) { infoflag = SiS_Pr->CInfoFlag; } else { - resindex = SiS_GetResInfo(SiS_Pr, ModeNo, ModeIdIndex); + SiS_GetResInfo(SiS_Pr, ModeNo, ModeIdIndex); if(ModeNo > 0x13) { infoflag = SiS_Pr->SiS_RefIndex[RRTI].Ext_InfoFlag; } @@ -3538,16 +3538,15 @@ SiS_Generic_ConvertCRData(struct SiS_Private *SiS_Pr, unsigned char *crdata, struct fb_var_screeninfo *var, bool writeres ) { - unsigned short HRE, HBE, HRS, HBS, HDE, HT; - unsigned short VRE, VBE, VRS, VBS, VDE, VT; + unsigned short HRE, HBE, HRS, HDE, HT; + unsigned short VRE, VBE, VRS, VDE, VT; unsigned char sr_data, cr_data, cr_data2; - int A, B, C, D, E, F, temp; + int B, C, D, E, F, temp; sr_data = crdata[14]; /* Horizontal total */ HT = crdata[0] | ((unsigned short)(sr_data & 0x03) << 8); - A = HT + 5; /* Horizontal display enable end */ HDE = crdata[1] | ((unsigned short)(sr_data & 0x0C) << 6); @@ -3557,9 +3556,6 @@ SiS_Generic_ConvertCRData(struct SiS_Private *SiS_Pr, unsigned char *crdata, HRS = crdata[4] | ((unsigned short)(sr_data & 0xC0) << 2); F = HRS - E - 3; - /* Horizontal blank start */ - HBS = crdata[2] | ((unsigned short)(sr_data & 0x30) << 4); - sr_data = crdata[15]; cr_data = crdata[5]; @@ -3593,7 +3589,6 @@ SiS_Generic_ConvertCRData(struct SiS_Private *SiS_Pr, unsigned char *crdata, ((unsigned short)(cr_data & 0x01) << 8) | ((unsigned short)(cr_data & 0x20) << 4) | ((unsigned short)(sr_data & 0x01) << 10); - A = VT + 2; /* Vertical display enable end */ VDE = crdata[10] | @@ -3611,12 +3606,6 @@ SiS_Generic_ConvertCRData(struct SiS_Private *SiS_Pr, unsigned char *crdata, cr_data2 = (crdata[16] & 0x01) << 5; - /* Vertical blank start */ - VBS = crdata[11] | - ((unsigned short)(cr_data & 0x08) << 5) | - ((unsigned short)(cr_data2 & 0x20) << 4) | - ((unsigned short)(sr_data & 0x04) << 8); - /* Vertical blank end */ VBE = crdata[12] | ((unsigned short)(sr_data & 0x10) << 4); temp = VBE - ((E - 1) & 511);