From patchwork Tue May 16 11:28:57 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 99866 Delivered-To: patch@linaro.org Received: by 10.140.96.100 with SMTP id j91csp1969845qge; Tue, 16 May 2017 04:29:17 -0700 (PDT) X-Received: by 10.98.18.157 with SMTP id 29mr11239444pfs.75.1494934157392; Tue, 16 May 2017 04:29:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1494934157; cv=none; d=google.com; s=arc-20160816; b=geTotUyqOAss7Q7KL/eAlZ2ZfMqm3m0wMs8TRjjgDQpU5OiFkCbDHEdiS9br/bPdOp /PalOgd4/AoGSxTTYpxUHaD7IjflZiOLbMSiZYssD1sAyMv5L8evchkwksVy7cZgf7zk HT2F1cut+hDumN8qKTuqDnCL+AxrecnWVW81sWc9fHwg8t1YClKIgmmfYtJKH6/fB8CC 83QqH9SOepRzSyBbuccJk4vIe9rlmCXZvVClj46b+h1ZL1I0ofj3USVM/0o2s7wNJNsF ISXTRi+ICnsafZEl51KU3ir7rWCDn3vmYD9Hd/Qvz4Wukqd46FJLQCm2Ccjd6wnGmFeo siZg== 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=ocUwuB+lRlfCBX8P1pUY1RcNBH2+RfC5mGz+LwvR790=; b=fQtoPfJn9Qqxmxux1pRGN6TxDaycQxyrv2GCWvRmMPzWmJw3blPgZeX6fhmmN5jGgp 1s9Jz3Qp2TJgTyw9e0LR+cdewB0mZG/A/Rv0qfvkGlBQtvMJWSFdV7jSmUGXTx3XS6fC p08Rna68/G50gL+R6wCEt1HBMaXugBKmgyqw9Mtxg4/A91HKbg1dThvFWeAnX9Mis7z/ e3aYceFiRyJBEqiyDm4c7iQ4z6eN9ZAwdZA0j2C+/3TCOap+BRkhnIBWJyr+rG+S04Qe UfUxnDG8XKpMe1y8xgu7eJbhWkIwDjbmLoDijCmZB3PGUOosEqAJCZfSSrE2CJCNXUyJ 5INw== 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 61si12945798plr.23.2017.05.16.04.29.17; Tue, 16 May 2017 04:29:17 -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 S1751436AbdEPL3Q (ORCPT + 2 others); Tue, 16 May 2017 07:29:16 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:50459 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751067AbdEPL3P (ORCPT ); Tue, 16 May 2017 07:29:15 -0400 Received: from wuerfel.lan ([78.42.17.5]) by mrelayeu.kundenserver.de (mreue001 [212.227.15.129]) with ESMTPA (Nemesis) id 0MHfTA-1d9VGh24Gi-003J1L; Tue, 16 May 2017 13:29:07 +0200 From: Arnd Bergmann To: Florian Tobias Schandinat , Bartlomiej Zolnierkiewicz Cc: Arnd Bergmann , linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] fbdev: via: remove possibly unused variables Date: Tue, 16 May 2017 13:28:57 +0200 Message-Id: <20170516112906.4144714-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:8965khaTF8IvWd04AvLn5QKVurr50mvpC75adMnYM4+SvGd7G+l /8VITWb8yZt0i+w1dKmZbJwxx5Tvlo0rhTlRNWsrgZ7xbkd/kSJ5huluSrQSiijTwh0MppJ bAiXByD6mIy8Dzat5+WMwqPiyty27dzVSL3l0vTtRKVAMpVmqqLvzHPxavdhdDQ6Qxs0Pou b0vZg9bjrFAzLCiWaCwKg== X-UI-Out-Filterresults: notjunk:1; V01:K0:2QOM/h31NWo=:esecuJ1R5H2x1dfnqWeqkf +GVr5GlIdzC4D11w3BRyQNrQHIajcQM68tIP2/MpjyKz6YzxqixI0p1I6NdzSWfKKxQe/Mk2j JvtDHL77ooq3zn3Nh6LSfjJuQfAY0GLq/geD7QiDU51GQ1KJa1IzTox3pek6cmrSP/pbcgU/B a4atKCBvGtxqOh7kN42Ph0FdXIIwGUfdjv4EJZvHSfKe1byuY6UqCszVjBpmY2Ww/2D/H/qNc 7ZLnThJbrYXjDPxKhWCAnb/QBQIQF+JZnKt5S6ANQ39aSId233caji/XHz4Rdz3RA6DmryJSF xGLM54Do2UV+j8FnpVcIcE+9yZCGf7gdea3MRPzdsQ+dtvLVOm3WnrhbwYSakB+YQf+AHUoGH ADUVlVVebbvgS1OZmzWSuFH9OoS9wJGlxdd68iLVYeCS1qkyeAwLvClqDOK7bqiw1tHyHUXmy 7itL5IzzKAywqyZfmWMURTWeiMpBODpiV954x2bZbaNtHPbDWbCj8TX5Ft9wm608rSi/HBkLp ERL11fOCcyzIjvr9LTagv4xyfh0sIBzo/vKAEOnfR5g7ApFMdHDUuHWSWO1U3R0fXtGrLB892 DcVZGNZje4oscW/yWpT7OsbLrtgZlf7E6/GY62roxIdGFNmENVvqSE0EZOigaKhYDzyUVoknp FdQJfTHS7SGpFA5vYyfbF+rbKLIaQsQaumZ6YDGg+ngXCoBG/Z35W000g/zdKfst8zDs= Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org When CONFIG_PROC_FS is disabled, we get warnings about unused variables as remove_proc_entry() evaluates to an empty macro. drivers/video/fbdev/via/viafbdev.c: In function 'viafb_remove_proc': drivers/video/fbdev/via/viafbdev.c:1635:4: error: unused variable 'iga2_entry' [-Werror=unused-variable] drivers/video/fbdev/via/viafbdev.c:1634:4: error: unused variable 'iga1_entry' [-Werror=unused-variable] These are easy to avoid by using the pointer from the structure. Signed-off-by: Arnd Bergmann --- drivers/video/fbdev/via/viafbdev.c | 8 +++----- 1 file changed, 3 insertions(+), 5 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/via/viafbdev.c b/drivers/video/fbdev/via/viafbdev.c index 510772bed4f4..89ee4d73bcff 100644 --- a/drivers/video/fbdev/via/viafbdev.c +++ b/drivers/video/fbdev/via/viafbdev.c @@ -1630,16 +1630,14 @@ static void viafb_init_proc(struct viafb_shared *shared) } static void viafb_remove_proc(struct viafb_shared *shared) { - struct proc_dir_entry *viafb_entry = shared->proc_entry, - *iga1_entry = shared->iga1_proc_entry, - *iga2_entry = shared->iga2_proc_entry; + struct proc_dir_entry *viafb_entry = shared->proc_entry; if (!viafb_entry) return; - remove_proc_entry("output_devices", iga2_entry); + remove_proc_entry("output_devices", shared->iga2_proc_entry); remove_proc_entry("iga2", viafb_entry); - remove_proc_entry("output_devices", iga1_entry); + remove_proc_entry("output_devices", shared->iga1_proc_entry); remove_proc_entry("iga1", viafb_entry); remove_proc_entry("supported_output_devices", viafb_entry);