Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1380615
| Path | csiph.com!weretis.net!feeder4.news.weretis.net!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Arnd Bergmann <arnd@arndb.de> |
| Newsgroups | linux.kernel |
| Subject | [PATCH] thermal: tegra: mark PM functions __maybe_unused |
| Date | Sat, 16 Apr 2016 22:30:02 +0200 |
| Message-ID | <roF0S-Ro-17@gated-at.bofh.it> (permalink) |
| X-Mailer | git-send-email 2.7.0 |
| X-Provags-ID | V03:K0:5egZPNho0y7o/qbJ9YarbW8PuwF8+1NkfE7yp6D69HDhHraYoU4 xMAT2DcQoC7h/mVhcVT1dwQyilHVPXUYr8f3a9/DObPlnGXnkWkQEN5H/G3B6ZTKLmm9CDC M6iWnBvjXZDPR/mtuuyqrJYAglOMQCpriM95CttSsewzdY9sdLYSrdN9o0ZWMG2Ueut/1lZ r/2hTFhpGw2k/OVVR9eKA== |
| X-Ui-Out-Filterresults | notjunk:1;V01:K0:/x9im3k0psw=:PsqQk0BKsjoCYRNIJ3W/Wt nRXJe4QAJ0fc7RQI07DajVWvfyS7l8yqNCvQ1RQ/yom+fdpNp+HdtUJQExJM7uldCp3QQXBdj sOPleqlBKZBJATlcenyCp60WSOPCwWaV8+nUjDK2A81AQjOrT0+diiMsgIi9ynpkaxPIqqcEf Z0RzqFQw8lpioUoZZT59K7PJ9DE12//nwmXRF2+EIkQ4xG8AIMBvmuutC8KbIcG/6gA+8kKkb Mhk14lDXVvewvrVtIFZbpxZcepqDrnHAzqxtA6WQnGGM4sPlApD/ogtVjhyQJph1BHUMl4KO2 f7S8a4MdYCT3COYADT2NXeSfNqe3n36WEQTVW/YrdP7G9hQvIi1xaD1yEXJRVOUMTZNvEPuvd XbNTtZTvBkW5RgLKhiXkN/L0+JdRoTVTPnpW6egJx4g9WW9YUcgRWpscwYFCp30Uh/D0BWsPL wdZQIJOP21p8ePOpcWdO7Bqfp/SeIlwBwzPx16fQsP9NQsQIdiCJbDVgJlcAtJvXxJhb065cV 4zAhdCc4IX7HVnQShj8b7F6VQYm6aLvv7L0JzBVzuN+9v/4wAYCo3YYQOxSpkq9Zp1ttZp7CG IrQPphVXIU+n4pf1WXWlaSN2CgJy1lFA44c2W089H5MRzTiygHCIc/7Kyl3JCoiC8X1vMjqh5 ptykL7DDr+5Ex92kZ+5HPrVJ5y0lS82yZLfAdFkAmwmkGGFOcmIVkgY1LdAmC1EP0cFY= |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 42 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | Arnd Bergmann <arnd@arndb.de>, Zhang Rui <rui.zhang@intel.com>, Stephen Warren <swarren@wwwdotorg.org>, Thierry Reding <thierry.reding@gmail.com>, Alexandre Courbot <gnurou@gmail.com>, linux-pm@vger.kernel.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org |
| X-Original-Date | Sat, 16 Apr 2016 22:19:33 +0200 |
| X-Original-Message-ID | <1460838026-1242452-1-git-send-email-arnd@arndb.de> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1380615 |
Show key headers only | View raw
After the PM support has been added to this driver, we get
a harmless warning when that support is disabled at compile
time:
drivers/thermal/tegra/soctherm.c:641:12: error: 'soctherm_resume' defined but not used [-Werror=unused-function]
static int soctherm_resume(struct device *dev)
This marks the two PM functions as __maybe_unused to shut up
the warning. This is preferred over adding an #ifdef around
them, as it is harder to get wrong, and provides better
compile-time coverage.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: a134b4143b65 ("thermal: tegra: add PM support")
---
drivers/thermal/tegra/soctherm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/thermal/tegra/soctherm.c b/drivers/thermal/tegra/soctherm.c
index 559c74279eb8..be829d6e131c 100644
--- a/drivers/thermal/tegra/soctherm.c
+++ b/drivers/thermal/tegra/soctherm.c
@@ -629,7 +629,7 @@ static int tegra_soctherm_remove(struct platform_device *pdev)
return 0;
}
-static int soctherm_suspend(struct device *dev)
+static int __maybe_unused soctherm_suspend(struct device *dev)
{
struct platform_device *pdev = to_platform_device(dev);
@@ -638,7 +638,7 @@ static int soctherm_suspend(struct device *dev)
return 0;
}
-static int soctherm_resume(struct device *dev)
+static int __maybe_unused soctherm_resume(struct device *dev)
{
struct platform_device *pdev = to_platform_device(dev);
struct tegra_soctherm *tegra = platform_get_drvdata(pdev);
--
2.7.0
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] thermal: tegra: mark PM functions __maybe_unused Arnd Bergmann <arnd@arndb.de> - 2016-04-16 22:30 +0200
Re: [PATCH] thermal: tegra: mark PM functions __maybe_unused Thierry Reding <thierry.reding@gmail.com> - 2016-04-18 09:20 +0200
Re: [PATCH] thermal: tegra: mark PM functions __maybe_unused Wei Ni <wni@nvidia.com> - 2016-04-19 04:40 +0200
Re: [PATCH] thermal: tegra: mark PM functions __maybe_unused Thierry Reding <thierry.reding@gmail.com> - 2016-04-19 14:50 +0200
Re: [PATCH] thermal: tegra: mark PM functions __maybe_unused Wei Ni <wni@nvidia.com> - 2016-04-20 08:50 +0200
csiph-web