From patchwork Sun Jan 19 12:17:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 11341529 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5AF0592A for ; Mon, 20 Jan 2020 08:58:45 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 439B52077C for ; Mon, 20 Jan 2020 08:58:45 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 439B52077C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CB2B26E868; Mon, 20 Jan 2020 08:58:37 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from huawei.com (szxga05-in.huawei.com [45.249.212.191]) by gabe.freedesktop.org (Postfix) with ESMTPS id 31C776E373 for ; Sun, 19 Jan 2020 12:18:29 +0000 (UTC) Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 9D748BB7BBD5755883CC; Sun, 19 Jan 2020 20:18:26 +0800 (CST) Received: from huawei.com (10.175.124.28) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Sun, 19 Jan 2020 20:18:17 +0800 From: yu kuai To: , Subject: [PATCH 1/4] video: fbdev: remove set but not used variable 'hSyncPol' Date: Sun, 19 Jan 2020 20:17:27 +0800 Message-ID: <20200119121730.10701-2-yukuai3@huawei.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20200119121730.10701-1-yukuai3@huawei.com> References: <20200119121730.10701-1-yukuai3@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.124.28] X-CFilter-Loop: Reflected X-Mailman-Approved-At: Mon, 20 Jan 2020 08:58:36 +0000 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, yi.zhang@huawei.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, zhengbin13@huawei.com, yukuai3@huawei.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes gcc '-Wunused-but-set-variable' warning: drivers/video/fbdev/aty/radeon_base.c: In function ‘radeonfb_set_par’: drivers/video/fbdev/aty/radeon_base.c:1653:6: warning: variable ‘hSyncPol’ set but not used [-Wunused-but-set-variable] It is never used, and so can be removed. Signed-off-by: yu kuai --- drivers/video/fbdev/aty/radeon_base.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c index 3af00e3b965e..d2e68ec580c2 100644 --- a/drivers/video/fbdev/aty/radeon_base.c +++ b/drivers/video/fbdev/aty/radeon_base.c @@ -1650,7 +1650,7 @@ static int radeonfb_set_par(struct fb_info *info) struct fb_var_screeninfo *mode = &info->var; struct radeon_regs *newmode; int hTotal, vTotal, hSyncStart, hSyncEnd, - hSyncPol, vSyncStart, vSyncEnd, vSyncPol, cSync; + vSyncStart, vSyncEnd, vSyncPol, cSync; u8 hsync_adj_tab[] = {0, 0x12, 9, 9, 6, 5}; u8 hsync_fudge_fp[] = {2, 2, 0, 0, 5, 5}; u32 sync, h_sync_pol, v_sync_pol, dotClock, pixClock; @@ -1730,7 +1730,6 @@ static int radeonfb_set_par(struct fb_info *info) else if (vsync_wid > 0x1f) /* max */ vsync_wid = 0x1f; - hSyncPol = mode->sync & FB_SYNC_HOR_HIGH_ACT ? 0 : 1; vSyncPol = mode->sync & FB_SYNC_VERT_HIGH_ACT ? 0 : 1; cSync = mode->sync & FB_SYNC_COMP_HIGH_ACT ? (1 << 4) : 0; From patchwork Sun Jan 19 12:17:28 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 11341537 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 92FCE17EA for ; Mon, 20 Jan 2020 08:58:59 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7BC192077C for ; Mon, 20 Jan 2020 08:58:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7BC192077C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 84FF36E880; Mon, 20 Jan 2020 08:58:40 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from huawei.com (szxga05-in.huawei.com [45.249.212.191]) by gabe.freedesktop.org (Postfix) with ESMTPS id 31F1E6E388 for ; Sun, 19 Jan 2020 12:18:29 +0000 (UTC) Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 98785683CF474A60389B; Sun, 19 Jan 2020 20:18:26 +0800 (CST) Received: from huawei.com (10.175.124.28) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Sun, 19 Jan 2020 20:18:18 +0800 From: yu kuai To: , Subject: [PATCH 2/4] video: fbdev: remove set but not used variable 'vSyncPol' Date: Sun, 19 Jan 2020 20:17:28 +0800 Message-ID: <20200119121730.10701-3-yukuai3@huawei.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20200119121730.10701-1-yukuai3@huawei.com> References: <20200119121730.10701-1-yukuai3@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.124.28] X-CFilter-Loop: Reflected X-Mailman-Approved-At: Mon, 20 Jan 2020 08:58:36 +0000 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, yi.zhang@huawei.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, zhengbin13@huawei.com, yukuai3@huawei.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes gcc '-Wunused-but-set-variable' warning: drivers/video/fbdev/aty/radeon_base.c: In function ‘radeonfb_set_par’: drivers/video/fbdev/aty/radeon_base.c:1653:38: warning: variable ‘vSyncPol’ set but not used [-Wunused-but-set-variable] It is never used, and so can be removed. Signed-off-by: yu kuai --- drivers/video/fbdev/aty/radeon_base.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c index d2e68ec580c2..0666f848bf70 100644 --- a/drivers/video/fbdev/aty/radeon_base.c +++ b/drivers/video/fbdev/aty/radeon_base.c @@ -1650,7 +1650,7 @@ static int radeonfb_set_par(struct fb_info *info) struct fb_var_screeninfo *mode = &info->var; struct radeon_regs *newmode; int hTotal, vTotal, hSyncStart, hSyncEnd, - vSyncStart, vSyncEnd, vSyncPol, cSync; + vSyncStart, vSyncEnd, cSync; u8 hsync_adj_tab[] = {0, 0x12, 9, 9, 6, 5}; u8 hsync_fudge_fp[] = {2, 2, 0, 0, 5, 5}; u32 sync, h_sync_pol, v_sync_pol, dotClock, pixClock; @@ -1730,8 +1730,6 @@ static int radeonfb_set_par(struct fb_info *info) else if (vsync_wid > 0x1f) /* max */ vsync_wid = 0x1f; - vSyncPol = mode->sync & FB_SYNC_VERT_HIGH_ACT ? 0 : 1; - cSync = mode->sync & FB_SYNC_COMP_HIGH_ACT ? (1 << 4) : 0; format = radeon_get_dstbpp(depth); From patchwork Sun Jan 19 12:17:29 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 11341543 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 43C5017EA for ; Mon, 20 Jan 2020 08:59:09 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2C8772077C for ; Mon, 20 Jan 2020 08:59:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2C8772077C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DE59B6E875; Mon, 20 Jan 2020 08:58:39 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from huawei.com (szxga05-in.huawei.com [45.249.212.191]) by gabe.freedesktop.org (Postfix) with ESMTPS id 30C8E6E35D for ; Sun, 19 Jan 2020 12:18:29 +0000 (UTC) Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id A6758F5E5F10B0003819; Sun, 19 Jan 2020 20:18:26 +0800 (CST) Received: from huawei.com (10.175.124.28) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Sun, 19 Jan 2020 20:18:18 +0800 From: yu kuai To: , Subject: [PATCH 3/4] video: fbdev: remove set but not used variable 'vSyncPol' Date: Sun, 19 Jan 2020 20:17:29 +0800 Message-ID: <20200119121730.10701-4-yukuai3@huawei.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20200119121730.10701-1-yukuai3@huawei.com> References: <20200119121730.10701-1-yukuai3@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.124.28] X-CFilter-Loop: Reflected X-Mailman-Approved-At: Mon, 20 Jan 2020 08:58:36 +0000 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, yi.zhang@huawei.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, zhengbin13@huawei.com, yukuai3@huawei.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes gcc '-Wunused-but-set-variable' warning: drivers/video/fbdev/aty/radeon_base.c: In function ‘radeonfb_set_par’: drivers/video/fbdev/aty/radeon_base.c:1653:48: warning: variable ‘cSync’ set but not used [-Wunused-but-set-variable] It is never used, and so can be removed. Signed-off-by: yu kuai --- drivers/video/fbdev/aty/radeon_base.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c index 0666f848bf70..7d2ee889ffcd 100644 --- a/drivers/video/fbdev/aty/radeon_base.c +++ b/drivers/video/fbdev/aty/radeon_base.c @@ -1650,7 +1650,7 @@ static int radeonfb_set_par(struct fb_info *info) struct fb_var_screeninfo *mode = &info->var; struct radeon_regs *newmode; int hTotal, vTotal, hSyncStart, hSyncEnd, - vSyncStart, vSyncEnd, cSync; + vSyncStart, vSyncEnd; u8 hsync_adj_tab[] = {0, 0x12, 9, 9, 6, 5}; u8 hsync_fudge_fp[] = {2, 2, 0, 0, 5, 5}; u32 sync, h_sync_pol, v_sync_pol, dotClock, pixClock; @@ -1730,8 +1730,6 @@ static int radeonfb_set_par(struct fb_info *info) else if (vsync_wid > 0x1f) /* max */ vsync_wid = 0x1f; - cSync = mode->sync & FB_SYNC_COMP_HIGH_ACT ? (1 << 4) : 0; - format = radeon_get_dstbpp(depth); bytpp = mode->bits_per_pixel >> 3; From patchwork Sun Jan 19 12:17:30 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 11341535 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AEC7792A for ; Mon, 20 Jan 2020 08:58:57 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9750D2077C for ; Mon, 20 Jan 2020 08:58:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9750D2077C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F140E6E86A; Mon, 20 Jan 2020 08:58:38 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from huawei.com (szxga05-in.huawei.com [45.249.212.191]) by gabe.freedesktop.org (Postfix) with ESMTPS id CCE7F6E35D for ; Sun, 19 Jan 2020 12:18:30 +0000 (UTC) Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id A20637D8C28224291A16; Sun, 19 Jan 2020 20:18:26 +0800 (CST) Received: from huawei.com (10.175.124.28) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.439.0; Sun, 19 Jan 2020 20:18:19 +0800 From: yu kuai To: , Subject: [PATCH 4/4] video: fbdev: remove set but not used variable 'bytpp' Date: Sun, 19 Jan 2020 20:17:30 +0800 Message-ID: <20200119121730.10701-5-yukuai3@huawei.com> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20200119121730.10701-1-yukuai3@huawei.com> References: <20200119121730.10701-1-yukuai3@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.124.28] X-CFilter-Loop: Reflected X-Mailman-Approved-At: Mon, 20 Jan 2020 08:58:36 +0000 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, yi.zhang@huawei.com, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, zhengbin13@huawei.com, yukuai3@huawei.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fixes gcc '-Wunused-but-set-variable' warning: drivers/video/fbdev/aty/radeon_base.c: In function ‘radeonfb_set_par’: drivers/video/fbdev/aty/radeon_base.c:1660:32: warning: variable ‘bytpp’ set but not used [-Wunused-but-set-variable] It is never used, and so can be removed. Signed-off-by: yu kuai --- drivers/video/fbdev/aty/radeon_base.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c index 7d2ee889ffcd..22b3ee4f2ffa 100644 --- a/drivers/video/fbdev/aty/radeon_base.c +++ b/drivers/video/fbdev/aty/radeon_base.c @@ -1657,7 +1657,7 @@ static int radeonfb_set_par(struct fb_info *info) int i, freq; int format = 0; int nopllcalc = 0; - int hsync_start, hsync_fudge, bytpp, hsync_wid, vsync_wid; + int hsync_start, hsync_fudge, hsync_wid, vsync_wid; int primary_mon = PRIMARY_MONITOR(rinfo); int depth = var_to_depth(mode); int use_rmx = 0; @@ -1731,7 +1731,6 @@ static int radeonfb_set_par(struct fb_info *info) vsync_wid = 0x1f; format = radeon_get_dstbpp(depth); - bytpp = mode->bits_per_pixel >> 3; if ((primary_mon == MT_DFP) || (primary_mon == MT_LCD)) hsync_fudge = hsync_fudge_fp[format-1];