From patchwork Fri Sep 1 18:05:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Arthur Grillo X-Patchwork-Id: 13372831 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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id DD882CA0FEF for ; Fri, 1 Sep 2023 18:06:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 1838510E831; Fri, 1 Sep 2023 18:06:13 +0000 (UTC) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8CACB10E831 for ; Fri, 1 Sep 2023 18:06:11 +0000 (UTC) Received: from fews02-sea.riseup.net (fews02-sea-pn.riseup.net [10.0.1.112]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx1.riseup.net (Postfix) with ESMTPS id 4RcmDg0F4RzDrj8; Fri, 1 Sep 2023 18:06:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1693591571; bh=DWXax1VVYxJLxtnHHUvwQtEKCPi0tNnnlOsivDnI+jw=; h=From:Date:Subject:To:Cc:From; b=jMgVAI62yyAGOyMSsAhzqyeyJU2rhJ9a/GN3BcXLjsROxSZvVCsSbcmhWlojc9Q7F SDJEknGIQiKnUeKmljuhpUvHBgFAymsShP2JBeWhsfYwqmv0I8XsFoH4RSPcld/72u K1CmuGXuL4DZ22nUi/NmWlq23PR3ApQjPvrUXvws= X-Riseup-User-ID: 4823884539E9B3C13ADCFB1C515D7D4A3A8AA806180CE3A2D768A06060843233 Received: from [127.0.0.1] (localhost [127.0.0.1]) by fews02-sea.riseup.net (Postfix) with ESMTPSA id 4RcmDN3TPVzFs1Q; Fri, 1 Sep 2023 18:05:56 +0000 (UTC) From: Arthur Grillo Date: Fri, 01 Sep 2023 15:05:50 -0300 Subject: [PATCH] drm/debugfs: Add inline to drm_debugfs_dev_init() to suppres -Wunused-function MIME-Version: 1.0 Message-Id: <20230901-debugfs-fix-unused-function-warning-v1-1-161dd0902975@riseup.net> X-B4-Tracking: v=1; b=H4sIAP0n8mQC/x2NSwoCQQwFrzJkbaBnRGG8irjoz+s2mygdW4Vh7 m5wWfDq1UaGLjC6TBt1vMXkoQ7zYaJ8j9rAUpxpCcsxrGHmgjRaNa7y5aHDULgOzS/3+BO7ijZ ekRJyKud4iuRPzw6f/yvX277/AEgifIh1AAAA To: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org 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: tales.aparecida@gmail.com, Maxime Ripard , mairacanal@riseup.net, Thomas Zimmermann , Andi Shyti , andrealmeid@riseup.net, Arthur Grillo , kernel test robot Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" When CONFIG_DEBUG_FS is not set -Wunused-function warnings appear, make the static function inline to suppress that. Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202309012114.T8Vlfaf8-lkp@intel.com/ Closes: https://lore.kernel.org/oe-kbuild-all/202309012131.FeakBzEj-lkp@intel.com/ Signed-off-by: Arthur Grillo Reviewed-by: Andi Shyti Reviewed-by: MaĆ­ra Canal --- include/drm/drm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- base-commit: 8e455145d8f163aefa6b9cc29478e0a9f82276e6 change-id: 20230901-debugfs-fix-unused-function-warning-9ebbecbd6a5a Best regards, diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h index 9850fe73b739..e2640dc64e08 100644 --- a/include/drm/drm_drv.h +++ b/include/drm/drm_drv.h @@ -584,7 +584,7 @@ static inline bool drm_firmware_drivers_only(void) #if defined(CONFIG_DEBUG_FS) void drm_debugfs_dev_init(struct drm_device *dev, struct dentry *root); #else -static void drm_debugfs_dev_init(struct drm_device *dev, struct dentry *root) +static inline void drm_debugfs_dev_init(struct drm_device *dev, struct dentry *root) { } #endif