Skip to content

Commit

Permalink
ASoC: rt5514: mark PM functions as __maybe_unused
Browse files Browse the repository at this point in the history
The new functions are only used when CONFIG_PM is enabled,
leading to a harmless warning:

sound/soc/codecs/rt5514-spi.c:474:12: error: 'rt5514_resume' defined but not used [-Werror=unused-function]
sound/soc/codecs/rt5514-spi.c:464:12: error: 'rt5514_suspend' defined but not used [-Werror=unused-function]

This marks them as __maybe_unused to make the build silent
again.

Fixes: 58f1c07 ("ASoC: rt5514: Voice wakeup support.")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
arndb authored and broonie committed Nov 10, 2017
1 parent e9c50aa commit 7e6358e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sound/soc/codecs/rt5514-spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ static int rt5514_spi_probe(struct spi_device *spi)
return 0;
}

static int rt5514_suspend(struct device *dev)
static int __maybe_unused rt5514_suspend(struct device *dev)
{
int irq = to_spi_device(dev)->irq;

Expand All @@ -471,7 +471,7 @@ static int rt5514_suspend(struct device *dev)
return 0;
}

static int rt5514_resume(struct device *dev)
static int __maybe_unused rt5514_resume(struct device *dev)
{
struct snd_soc_platform *platform = snd_soc_lookup_platform(dev);
struct rt5514_dsp *rt5514_dsp =
Expand Down

0 comments on commit 7e6358e

Please sign in to comment.