Received: by 10.223.148.5 with SMTP id 5csp7569407wrq; Thu, 18 Jan 2018 06:59:25 -0800 (PST) X-Google-Smtp-Source: ACJfBosW68n8CXAQElh6JhdM8q/ZY4Ca7FSu9g7Mjfm4gG3TMspxW56856hhNP2CbEJCVadB/tBE X-Received: by 10.98.185.14 with SMTP id z14mr638306pfe.185.1516287565459; Thu, 18 Jan 2018 06:59:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516287565; cv=none; d=google.com; s=arc-20160816; b=xEzHY/ASsxVug8ko1qyC8bdztUVzQ4b7ZUNVYHvQnH6dLGT8h1bZF/PeWXUNxJ1WIT djUZpbY/yxzX7n9P5JiUbDZmbgteQqCvvpZZFnnnJy8NsKO13039x4yg3xO85rf5Xhfl CkzNbu3C6SL8vZsNWdCMkhEi3raDV+1NviOVgI9KEVGvJcndvbt1RrmTxSsxfrCmDGN4 jmpU4YcI0aRSIwG5IQF91bel4ulLjmUjo7sW1yLkcBZiHEtuCYeZXhD0/rojN7w8oQEp /kCuFowHaomVi1nP5afTG4AgN7yESTk+i8UR2YlLHnrejYtBrkhtRkg5/Wsll2PCrmvC C9YA== 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 q11si6086313pgc.824.2018.01.18.06.59.10; Thu, 18 Jan 2018 06:59:25 -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 S1755990AbeARNFW (ORCPT + 99 others); Thu, 18 Jan 2018 08:05:22 -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(-) 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); -- 2.9.0