* [PATCH] memory: tegra: avoid unused function warnings
@ 2020-04-08 19:00 Arnd Bergmann
[not found] ` <20200408190043.532711-1-arnd-r2nGTMty4D4@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Arnd Bergmann @ 2020-04-08 19:00 UTC (permalink / raw)
To: Thierry Reding, Jonathan Hunter
Cc: Arnd Bergmann, Thierry Reding, linux-tegra-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
The suspend/resume functions have no callers depending on
configuration, so they must be marked __maybe_unused to
avoid these harmless warnings:
drivers/memory/tegra/tegra186.c:1578:12: error: 'tegra186_mc_resume' defined but not used [-Werror=unused-function]
1578 | static int tegra186_mc_resume(struct device *dev)
| ^~~~~~~~~~~~~~~~~~
drivers/memory/tegra/tegra186.c:1573:12: error: 'tegra186_mc_suspend' defined but not used [-Werror=unused-function]
1573 | static int tegra186_mc_suspend(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~
Fixes: 177602b00641 ("memory: tegra: Add system sleep support")
Signed-off-by: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
---
drivers/memory/tegra/tegra186.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/memory/tegra/tegra186.c b/drivers/memory/tegra/tegra186.c
index 5d53f11ca7b6..e25c954dde2e 100644
--- a/drivers/memory/tegra/tegra186.c
+++ b/drivers/memory/tegra/tegra186.c
@@ -1570,12 +1570,12 @@ static const struct of_device_id tegra186_mc_of_match[] = {
};
MODULE_DEVICE_TABLE(of, tegra186_mc_of_match);
-static int tegra186_mc_suspend(struct device *dev)
+static int __maybe_unused tegra186_mc_suspend(struct device *dev)
{
return 0;
}
-static int tegra186_mc_resume(struct device *dev)
+static int __maybe_unused tegra186_mc_resume(struct device *dev)
{
struct tegra186_mc *mc = dev_get_drvdata(dev);
--
2.26.0
^ permalink raw reply related [flat|nested] 3+ messages in thread[parent not found: <20200408190043.532711-1-arnd-r2nGTMty4D4@public.gmane.org>]
* Re: [PATCH] memory: tegra: avoid unused function warnings [not found] ` <20200408190043.532711-1-arnd-r2nGTMty4D4@public.gmane.org> @ 2020-04-09 15:01 ` Thierry Reding 2020-05-07 20:02 ` Thierry Reding 1 sibling, 0 replies; 3+ messages in thread From: Thierry Reding @ 2020-04-09 15:01 UTC (permalink / raw) To: Arnd Bergmann Cc: Thierry Reding, Jonathan Hunter, linux-tegra-u79uwXL29TY76Z2rM5mHXA, linux-kernel-u79uwXL29TY76Z2rM5mHXA [-- Attachment #1: Type: text/plain, Size: 1140 bytes --] On Wed, Apr 08, 2020 at 09:00:30PM +0200, Arnd Bergmann wrote: > The suspend/resume functions have no callers depending on > configuration, so they must be marked __maybe_unused to > avoid these harmless warnings: > > drivers/memory/tegra/tegra186.c:1578:12: error: 'tegra186_mc_resume' defined but not used [-Werror=unused-function] > 1578 | static int tegra186_mc_resume(struct device *dev) > | ^~~~~~~~~~~~~~~~~~ > drivers/memory/tegra/tegra186.c:1573:12: error: 'tegra186_mc_suspend' defined but not used [-Werror=unused-function] > 1573 | static int tegra186_mc_suspend(struct device *dev) > | ^~~~~~~~~~~~~~~~~~~ > > Fixes: 177602b00641 ("memory: tegra: Add system sleep support") > Signed-off-by: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org> > --- > drivers/memory/tegra/tegra186.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Do you want to apply this to ARM SoC directly or would you prefer if I collected fixes and send a PR sometime later in the cycle? If the former: Acked-by: Thierry Reding <treding-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org> [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] memory: tegra: avoid unused function warnings [not found] ` <20200408190043.532711-1-arnd-r2nGTMty4D4@public.gmane.org> 2020-04-09 15:01 ` Thierry Reding @ 2020-05-07 20:02 ` Thierry Reding 1 sibling, 0 replies; 3+ messages in thread From: Thierry Reding @ 2020-05-07 20:02 UTC (permalink / raw) To: Arnd Bergmann Cc: Jonathan Hunter, Thierry Reding, linux-tegra-u79uwXL29TY76Z2rM5mHXA, linux-kernel-u79uwXL29TY76Z2rM5mHXA [-- Attachment #1: Type: text/plain, Size: 959 bytes --] On Wed, Apr 08, 2020 at 09:00:30PM +0200, Arnd Bergmann wrote: > The suspend/resume functions have no callers depending on > configuration, so they must be marked __maybe_unused to > avoid these harmless warnings: > > drivers/memory/tegra/tegra186.c:1578:12: error: 'tegra186_mc_resume' defined but not used [-Werror=unused-function] > 1578 | static int tegra186_mc_resume(struct device *dev) > | ^~~~~~~~~~~~~~~~~~ > drivers/memory/tegra/tegra186.c:1573:12: error: 'tegra186_mc_suspend' defined but not used [-Werror=unused-function] > 1573 | static int tegra186_mc_suspend(struct device *dev) > | ^~~~~~~~~~~~~~~~~~~ > > Fixes: 177602b00641 ("memory: tegra: Add system sleep support") > Signed-off-by: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org> > --- > drivers/memory/tegra/tegra186.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Applied to for-5.8/memory, thanks. Thierry [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-05-07 20:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-08 19:00 [PATCH] memory: tegra: avoid unused function warnings Arnd Bergmann
[not found] ` <20200408190043.532711-1-arnd-r2nGTMty4D4@public.gmane.org>
2020-04-09 15:01 ` Thierry Reding
2020-05-07 20:02 ` Thierry Reding
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).