diff mbox

ASoC: tas2552: Fix compilation warning for !PM_RUNTIME

Message ID 1412234880-8308-1-git-send-email-thierry.reding@gmail.com (mailing list archive)
State Accepted
Commit be1aa3ea1f4179cbc84c57d3b1128c49515910ac
Headers show

Commit Message

Thierry Reding Oct. 2, 2014, 7:28 a.m. UTC
From: Thierry Reding <treding@nvidia.com>

The tas2552_sw_shutdown() function is only used by runtime suspend
support, so only build it when necessary.

Signed-off-by: Thierry Reding <treding@nvidia.com>
---
 sound/soc/codecs/tas2552.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Mark Brown Oct. 2, 2014, 10:52 a.m. UTC | #1
On Thu, Oct 02, 2014 at 09:28:00AM +0200, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
> 
> The tas2552_sw_shutdown() function is only used by runtime suspend
> support, so only build it when necessary.

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/codecs/tas2552.c b/sound/soc/codecs/tas2552.c
index 1ed57a7e57b6..f039dc825971 100644
--- a/sound/soc/codecs/tas2552.c
+++ b/sound/soc/codecs/tas2552.c
@@ -115,6 +115,7 @@  static const struct snd_soc_dapm_route tas2552_audio_map[] = {
 	{"ClassD", NULL, "PLL"},
 };
 
+#ifdef CONFIG_PM_RUNTIME
 static void tas2552_sw_shutdown(struct tas2552_data *tas_data, int sw_shutdown)
 {
 	u8 cfg1_reg;
@@ -127,6 +128,7 @@  static void tas2552_sw_shutdown(struct tas2552_data *tas_data, int sw_shutdown)
 	snd_soc_update_bits(tas_data->codec, TAS2552_CFG_1,
 						 TAS2552_SWS_MASK, cfg1_reg);
 }
+#endif
 
 static int tas2552_hw_params(struct snd_pcm_substream *substream,
 			     struct snd_pcm_hw_params *params,