From patchwork Thu Jan 18 13:04:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 124945 Delivered-To: patch@linaro.org Received: by 10.46.64.27 with SMTP id n27csp117568lja; Thu, 18 Jan 2018 05:05:26 -0800 (PST) X-Google-Smtp-Source: ACJfBot5oJK62S5EgQSi5kalvCRTSl3ZkMHfYasHTgee0NoansDcAOwKKHHXUTocdNfHck3Hqsc/ X-Received: by 10.99.190.15 with SMTP id l15mr836629pgf.197.1516280726519; Thu, 18 Jan 2018 05:05:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516280726; cv=none; d=google.com; s=arc-20160816; b=lHTdIvqmwaNzra0yUaJsMx6HXjC3amfH/oghe+e/o+gYmIqazfOdwRDaiGRiYXn1/i 62b7y0RUvSY0Da/W2AZwV2+abXmN8SF7rnvCxWG0LqqPy/D9djVhVuYgs5ZeYI8TlPY4 4pUiAyAMPdhWhB69ovRdlxOsjN6uxTcejDoSUBPFlbuD6c11D5quUkJz6r5Rdbo+j7SD 32GVu7YIV4rrhVD8aj/WSONTumXkB7XhQ4h7jjhyzgb/HIkiyW0erpGIPInEhRx0O6T1 +URIZ5tiNjAjthhpmrj2Tx7izr9CmTy1smfPIoN4v975pqgivrnp8R3xvmQDd0qKzJLd PmGw== 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=QzlwW4ZSiPWmLJ/KGWfhh1kl8xP0bZ0Ja954NSYuuzY=; b=kIFAHJdnBMPMuDeeh74hHi5BahPUM4e3CpnqxaHsu7C516RLY5eFhrKrNC5pgcQKws 4v7AOCsjZebIWUAkabtBtlYgRRnuQVTsRQRofxSbceUwNzMeyrcobVmGBCaikrUGai7F EZrxdQa2+PfWQAaCvzav/5ZA6+L9XS9wkS35BODvtPFU/YkhmE5ImZifnw6sTFS6K6IY /vlSbFaG5VsRncRLUTYD/G8DN4jAagHsu7ZlTUZoujF9uJ2XLebLoMn5swccuexk9wTA g7V/ikWqq2q5YoQbd7/3XZScXyLvbXE4Ugyv/0E2Fe5QZrN1ZprV4PGcdNM4kRiGHbrl XtCg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 w14si5782730pgv.95.2018.01.18.05.05.26; Thu, 18 Jan 2018 05:05:26 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756000AbeARNFX (ORCPT + 28 others); Thu, 18 Jan 2018 08:05:23 -0500 Received: from mout.kundenserver.de ([212.227.126.187]:51462 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754998AbeARNFV (ORCPT ); Thu, 18 Jan 2018 08:05:21 -0500 Received: from wuerfel.lan ([95.208.111.237]) by mrelayeu.kundenserver.de (mreue007 [212.227.15.129]) with ESMTPA (Nemesis) id 0M7z2j-1eyLQx2PEP-00vgpg; Thu, 18 Jan 2018 14:05:14 +0100 From: Arnd Bergmann To: Wolfgang Grandegger , Marc Kleine-Budde Cc: Arnd Bergmann , Mario Huettel , Faiz Abbas , Oliver Hartkopp , Quentin Schulz , Franklin S Cooper Jr , linux-can@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] can: m_can: mark runtime-PM handlers as __maybe_unused Date: Thu, 18 Jan 2018 14:04:42 +0100 Message-Id: <20180118130513.506569-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:6R3QenuHmZrnFc1ZWuAfd2y/bw3cWfsVwKLEnhCiyETGfvQh2x+ aOiHssC9gPVIi0N35D8YzkXyXlmHDRk/bI3qGXmtzllnGHOCpkb0IZLm2yocvFm4wS95JCT SIAZM7WNF2WWvKbJofwwvybMkJhBdXoKvPCc3bX4O/TOWEKq+7iTgN7KranzsVBfdcwtwBj CLJv3vco5kWY33auNAoTQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:lKpM+1aPqVo=:g3B4HVhboGviPAXSce35Mf 1H3gWgXKTZle9bCsqbNwOXsqfN9KqvazNuogyJg6jZu7gRD7FWno4zJFQdq4+yMveVPQre7O7 0vCYDYxmC4cG9bWq7cW4NHTlu77U0ybUn3LpqL/K0XVTMXGicAcxt99VfVgRGfttkdC/hyOnJ sTql3g9o25Xj26mB8z87nbli3Qz/5ICIKvLb9HNWvOabulyKnguOjbQ1QK09/brnEdjDR9nYQ +vNsg6wcT4a2VZaPu+fRnB7mUjGVsSRwnav2jIs90dpxOdBuvZmY0990+ll4Hbb8iX1aFUAXx zYIPGR5p/OL01N7K7oQoal2LYcwiFJjrgz91YV7DMs5hr+tNhVAhKsDyCS6PBkUa6TbGmrhUO XxJBZsD01NkljU5w0TFAVEIS6s14aM654E1f6DBpnA+kVBTIa9xuSh+aDfSXgYRLqvGemANJW nWIFr+56mQggMFKgc+LrE2YF4AZMF+ifY8jNgnJK67f7OrznoIficVGJhUZcViyYbCcFwHuOf zz84Zrr1nBQeEgwbX5OL8AvwjQyE+go7AYS1ohOodxNS52mFr0AAQcwxz0Y7e+tLZkkT3uhiJ FPcejUsnxHgyDktKHHspxg8GeXiG6DIW6Ck2toao0gGuOx9A6Izy9SVmYJW/tBFZGL8QlTKcE pfP3nttaLr3aRYqvfS3NZmvz11Hp0opH1rqZrvxqRcCFM3E+k8pAwAOh9DJZZhtgoZQEsWenz 0dtKXiyKCk1zHzlJwgJxOivEKLdxQX/WRWP2Gw== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Building without CONFIG_PM results in a harmless warning: drivers/net/can/m_can/m_can.c:1763:12: error: 'm_can_runtime_resume' defined but not used [-Werror=unused-function] drivers/net/can/m_can/m_can.c:1752:12: error: 'm_can_runtime_suspend' defined but not used [-Werror=unused-function] Marking the functions as __maybe_unused lets the compiler silently drop them instead. Fixes: cdf8259d6573 ("can: m_can: Add PM Support") Signed-off-by: Arnd Bergmann --- drivers/net/can/m_can/m_can.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.9.0 diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index 49ed8737871f..2594f7779c6f 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -1749,7 +1749,7 @@ static int m_can_plat_remove(struct platform_device *pdev) return 0; } -static int m_can_runtime_suspend(struct device *dev) +static int __maybe_unused m_can_runtime_suspend(struct device *dev) { struct net_device *ndev = dev_get_drvdata(dev); struct m_can_priv *priv = netdev_priv(ndev); @@ -1760,7 +1760,7 @@ static int m_can_runtime_suspend(struct device *dev) return 0; } -static int m_can_runtime_resume(struct device *dev) +static int __maybe_unused m_can_runtime_resume(struct device *dev) { struct net_device *ndev = dev_get_drvdata(dev); struct m_can_priv *priv = netdev_priv(ndev);