| From 3d692ada74fe17ce2a416d77cb24ea5924b5e439 Mon Sep 17 00:00:00 2001 |
| From: Arnd Bergmann <arnd@arndb.de> |
| Date: Wed, 28 Mar 2018 16:53:10 +0200 |
| Subject: [PATCH 0929/1795] ASoC: rsnd: mark PM functions __maybe_unused |
| |
| The suspend/resume callbacks are now optional, leading to a warning |
| when they are unused: |
| |
| sound/soc/sh/rcar/core.c:1548:12: error: 'rsnd_resume' defined but not used [-Werror=unused-function] |
| static int rsnd_resume(struct device *dev) |
| ^~~~~~~~~~~ |
| sound/soc/sh/rcar/core.c:1539:12: error: 'rsnd_suspend' defined but not used [-Werror=unused-function] |
| static int rsnd_suspend(struct device *dev) |
| |
| This marks the as __maybe_unused to avoid the warning. |
| |
| Fixes: f8a9a29c4fe9 ("ASoC: rsnd: set pm_ops in hibernate-compatible way") |
| Signed-off-by: Arnd Bergmann <arnd@arndb.de> |
| Signed-off-by: Mark Brown <broonie@kernel.org> |
| (cherry picked from commit 6f5427039c33e149b711c0f973fcac7f6875b768) |
| Signed-off-by: Simon Horman <horms+renesas@verge.net.au> |
| Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> |
| --- |
| sound/soc/sh/rcar/core.c | 4 ++-- |
| 1 file changed, 2 insertions(+), 2 deletions(-) |
| |
| diff --git a/sound/soc/sh/rcar/core.c b/sound/soc/sh/rcar/core.c |
| index 96526c91a94b..be92c11a22bb 100644 |
| --- a/sound/soc/sh/rcar/core.c |
| +++ b/sound/soc/sh/rcar/core.c |
| @@ -1550,7 +1550,7 @@ static int rsnd_remove(struct platform_device *pdev) |
| return ret; |
| } |
| |
| -static int rsnd_suspend(struct device *dev) |
| +static int __maybe_unused rsnd_suspend(struct device *dev) |
| { |
| struct rsnd_priv *priv = dev_get_drvdata(dev); |
| |
| @@ -1559,7 +1559,7 @@ static int rsnd_suspend(struct device *dev) |
| return 0; |
| } |
| |
| -static int rsnd_resume(struct device *dev) |
| +static int __maybe_unused rsnd_resume(struct device *dev) |
| { |
| struct rsnd_priv *priv = dev_get_drvdata(dev); |
| |
| -- |
| 2.19.0 |
| |