From patchwork Fri Nov 3 17:35:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 13444819 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4398BC4332F for ; Fri, 3 Nov 2023 17:36:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229730AbjKCRgH (ORCPT ); Fri, 3 Nov 2023 13:36:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230101AbjKCRgG (ORCPT ); Fri, 3 Nov 2023 13:36:06 -0400 Received: from metis.whiteo.stw.pengutronix.de (metis.whiteo.stw.pengutronix.de [IPv6:2a0a:edc0:2:b01:1d::104]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CFCD1D54 for ; Fri, 3 Nov 2023 10:36:03 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qyy5R-0004Wt-Nj; Fri, 03 Nov 2023 18:36:01 +0100 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qyy5R-006NKM-5q; Fri, 03 Nov 2023 18:36:01 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1qyy5Q-00CUUo-Se; Fri, 03 Nov 2023 18:36:00 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Helge Deller Cc: Tomi Valkeinen , linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, kernel@pengutronix.de Subject: [PATCH] fbdev: omapfb: Drop unused remove function Date: Fri, 3 Nov 2023 18:35:58 +0100 Message-ID: <20231103173557.3639484-2-u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.42.0 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1451; i=u.kleine-koenig@pengutronix.de; h=from:subject; bh=Pa/PZpA5LZpLFCrixqqTeyvjev8rwBS2ffBdngiT/bo=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBlRS9+pvyHnfIDX2L26lFQyBi7dT6romTz0XqMS 93UFNxEGGiJATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZUUvfgAKCRCPgPtYfRL+ TlFsB/0e8vL7LYOd70imHwL3kg/uTtJ33J4rI+aK4VoBp82iIlkZONKRFta9zpssQWlm8mm0X0C JLzoGdN3WQXYV0bg3Nd3HV6jb/VKvUlZSxH3BQAVOwR89Xuy0uCrwYTpPktGGV8cQwBqQOi6wdE Pza+A/ErT2D+D/4OhiCl2BDP5cGwcuBMiWUKY2GkYvJpnfz8sq5fYHvRzLwKihL3hF7kcGcVA4x gupf/3xnK7wUAWdoXWLe6hOeM/l79BBfIPHXTylfJveMCKrk+q3UumOrhkuuqoaOyIf6V0Ii6pu +D+xlW6AxippRvAEfJm+vR4Xt1W8Nak7D+tGvEVyW3TqUUYn X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-fbdev@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org OMAP2_VRFB is a bool, so the vrfb driver can never be compiled as a module. With that __exit_p(vrfb_remove) always evaluates to NULL and vrfb_remove() is unused. If the driver was compilable as a module, it would fail to build because the type of vrfb_remove() isn't compatible with struct platform_driver::remove(). (The former returns void, the latter int.) Fixes: aa1e49a3752f ("OMAPDSS: VRFB: add omap_vrfb_supported()") Signed-off-by: Uwe Kleine-König --- drivers/video/fbdev/omap2/omapfb/vrfb.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) base-commit: e27090b1413ff236ca1aec26d6b022149115de2c diff --git a/drivers/video/fbdev/omap2/omapfb/vrfb.c b/drivers/video/fbdev/omap2/omapfb/vrfb.c index ee0dd4c6a646..568e6e1eca62 100644 --- a/drivers/video/fbdev/omap2/omapfb/vrfb.c +++ b/drivers/video/fbdev/omap2/omapfb/vrfb.c @@ -368,17 +368,10 @@ static int __init vrfb_probe(struct platform_device *pdev) return 0; } -static void __exit vrfb_remove(struct platform_device *pdev) -{ - vrfb_loaded = false; -} - static struct platform_driver vrfb_driver = { .driver.name = "omapvrfb", - .remove = __exit_p(vrfb_remove), }; - -module_platform_driver_probe(vrfb_driver, vrfb_probe); +builtin_platform_driver_probe(vrfb_driver, vrfb_probe); MODULE_AUTHOR("Tomi Valkeinen "); MODULE_DESCRIPTION("OMAP VRFB");