Skip to contentSkip to conversation

ASoC: boardwell: Drop unnecessary snd_soc_dapm_enable() calls

PATCH Applied Lars-Peter Clausen 2 participants 2 messages Jan 1, 2015 – Jan 5, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ASoC: boardwell: Drop unnecessary snd_soc_dapm_enable() calls

DAPM widgets are enabled by default, there is no need to enable them unless they have previously been explicitly disabled.

---
 sound/soc/intel/broadwell.c | 10 ----------
 1 file changed, 10 deletions(-)
sound/soc/intel/broadwell.c +0 -10
index 7cf95d5..9cf7d01 100644
@@ -140,8 +140,6 @@ static struct snd_soc_ops broadwell_rt286_ops = {
 
 static int broadwell_rtd_init(struct snd_soc_pcm_runtime *rtd)
 {
-	struct snd_soc_codec *codec = rtd->codec;
-	struct snd_soc_dapm_context *dapm = &codec->dapm;
 	struct sst_pdata *pdata = dev_get_platdata(rtd->platform->dev);
 	struct sst_hsw *broadwell = pdata->dsp;
 	int ret;
@@ -155,14 +153,6 @@ static int broadwell_rtd_init(struct snd_soc_pcm_runtime *rtd)
 		return ret;
 	}
 
-	/* always connected - check HP for jack detect */
-	snd_soc_dapm_enable_pin(dapm, "Headphone Jack");
-	snd_soc_dapm_enable_pin(dapm, "Speaker");
-	snd_soc_dapm_enable_pin(dapm, "Mic Jack");
-	snd_soc_dapm_enable_pin(dapm, "Line Jack");
-	snd_soc_dapm_enable_pin(dapm, "DMIC1");
-	snd_soc_dapm_enable_pin(dapm, "DMIC2");
-
 	return 0;
 }
 
Signature · 1 line
1.8.0
maintainer Applied
#1 lore raw
Quoted 2 lines · Lars-Peter Clausen

DAPM widgets are enabled by default, there is no need to enable them unless they have previously been explicitly disabled.

Applied, thanks.