Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752479AbdF0Phi (ORCPT ); Tue, 27 Jun 2017 11:37:38 -0400 Received: from mout.kundenserver.de ([212.227.17.10]:51951 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751513AbdF0Ph3 (ORCPT ); Tue, 27 Jun 2017 11:37:29 -0400 From: Arnd Bergmann To: Olof Johansson Cc: Arnd Bergmann , Enric Balletbo i Serra , Guenter Roeck , Lee Jones , Jonathan Cameron , Benson Leung , Eric Caruso , Gwendal Grignou , Vincent Palatin , Jeffery Yu , Logan Gunthorpe , linux-kernel@vger.kernel.org Subject: [PATCH] platform/chrome: cros_ec_lightbar - hide unused PM functions Date: Tue, 27 Jun 2017 17:36:36 +0200 Message-Id: <20170627153705.1378256-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:ae24NBlWpsogb+fRLDxjdEXvtgMfzeOo8oKB/n3w8cKEr1wpBiB OC20ffAvX/c3w6lZgqiX+alyIBiIISnNP2psxtru5GF4JCMsVjohFAAj5OiYFce0L4b9rWe qkdBlYSfOkiCe6ld7qgWQJK8mGc8N+lfBvPUBFPWN7vUJzhOGTnlAswNwCYbb9ep1VS6cfv 7cxZuqtq/NPiupZsYW17w== X-UI-Out-Filterresults: notjunk:1;V01:K0:l2VaoHJONgE=:Lp1/L4TJXz9MaCWD6IGjWO FvKMN/Xx2vtSof/QiJP0W/8L/Rd3Xnbj03dMsVO8G+e9uwBz2HwAcm5l8uBt5TfAbPoAweeYR Ol+tYtMbEPr0DDHRF4e/fUCx87gvcB1jyMg1rjwn3cybOQPmXk558xMys9RwMPm4yxAaQdPTF jT6qgGKcEiG1eUF6vHISq4RCQ8u/4ezrBTiPF9WXoYXpSvuqYQTDh7YhZbhUN0cXTFUxsd5qd MUOHq/CqDmr9JLyqzoU3v/rvCF2SH4AlP/Q033zuRf3dcwiroG2QlSw1RgTuGB+H4gf2AekdI t2wHkv6L5318FKYBonXkH7vIt7rMLaLE6i921dMHVbHNQiLUWY3y5bCOlDLNIje2kYF1wjM6q +o7QKmoDZP1o8KLBxYG6cI5KBUSb8CmxlLzsso4HqS91EPIlsve6FwXLRW8kbzbNv6XenqX1j mr4PckfvszisEPz4lPdJz89w7Cf/mymhuw5fU8Ss2LayyPnSdwAF4TljL2OGsiDnQQsq4f/5H GR6icF5xcxMcd33XpswCznk027kSbrFdgc6iaG9rDeYq8LlOFmwsXd7Zk20nhcyfpoSGZb3p/ yLxmgMm6DDjQgBZ4jFRIBvBN/LQ1PYPCpg4c1Y+Z9III8NKPjGvKyJCX5S/S9mK8FqtKS061Y HLzKO9Iyhw8IP45FOFKBEuwad/bsLIN6v3El2pYRCInfHX3O6A6aLD1R5bvn/WdvkETc= Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1466 Lines: 39 The only reference to the new functions is inside of an #ifdef, which now causes a harmless warning when CONFIG_PM_SLEEP is not set: chrome/cros_ec_dev.c:478:12: error: 'ec_device_resume' defined but not used [-Werror=unused-function] chrome/cros_ec_dev.c:469:12: error: 'ec_device_suspend' defined but not used [-Werror=unused-function] This marks the two functions as __maybe_unused so they can get silently dropped by the compiler. Fixes: 405c84308c43 ("platform/chrome: cros_ec_lightbar - Control of suspend/resume lightbar sequence") Signed-off-by: Arnd Bergmann --- drivers/platform/chrome/cros_ec_dev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/chrome/cros_ec_dev.c b/drivers/platform/chrome/cros_ec_dev.c index b9bf086f7569..cf6c4f0846b8 100644 --- a/drivers/platform/chrome/cros_ec_dev.c +++ b/drivers/platform/chrome/cros_ec_dev.c @@ -466,7 +466,7 @@ static const struct platform_device_id cros_ec_id[] = { }; MODULE_DEVICE_TABLE(platform, cros_ec_id); -static int ec_device_suspend(struct device *dev) +static __maybe_unused int ec_device_suspend(struct device *dev) { struct cros_ec_dev *ec = dev_get_drvdata(dev); @@ -475,7 +475,7 @@ static int ec_device_suspend(struct device *dev) return 0; } -static int ec_device_resume(struct device *dev) +static __maybe_unused int ec_device_resume(struct device *dev) { struct cros_ec_dev *ec = dev_get_drvdata(dev); -- 2.9.0