Skip to content

Commit

Permalink
Merge remote-tracking branches 'asoc/topic/wm8991', 'asoc/topic/wm899…
Browse files Browse the repository at this point in the history
…3', 'asoc/topic/wm8994', 'asoc/topic/wm8995' and 'asoc/topic/wm9081' into asoc-next
  • Loading branch information
Mark Brown committed Dec 8, 2014
6 parents e45f607 + 497b900 + 77d05e7 + 49d9ac3 + aee9ffa + 68201d6 commit f234833
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 61 deletions.
32 changes: 2 additions & 30 deletions sound/soc/codecs/wm8991.c
Original file line number Diff line number Diff line change
Expand Up @@ -1227,32 +1227,6 @@ static int wm8991_set_bias_level(struct snd_soc_codec *codec,
return 0;
}

static int wm8991_suspend(struct snd_soc_codec *codec)
{
wm8991_set_bias_level(codec, SND_SOC_BIAS_OFF);
return 0;
}

static int wm8991_resume(struct snd_soc_codec *codec)
{
wm8991_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
return 0;
}

/* power down chip */
static int wm8991_remove(struct snd_soc_codec *codec)
{
wm8991_set_bias_level(codec, SND_SOC_BIAS_OFF);
return 0;
}

static int wm8991_probe(struct snd_soc_codec *codec)
{
wm8991_set_bias_level(codec, SND_SOC_BIAS_STANDBY);

return 0;
}

#define WM8991_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE |\
SNDRV_PCM_FMTBIT_S24_LE)

Expand Down Expand Up @@ -1293,11 +1267,9 @@ static struct snd_soc_dai_driver wm8991_dai = {
};

static struct snd_soc_codec_driver soc_codec_dev_wm8991 = {
.probe = wm8991_probe,
.remove = wm8991_remove,
.suspend = wm8991_suspend,
.resume = wm8991_resume,
.set_bias_level = wm8991_set_bias_level,
.suspend_bias_off = true,

.controls = wm8991_snd_controls,
.num_controls = ARRAY_SIZE(wm8991_snd_controls),
.dapm_widgets = wm8991_dapm_widgets,
Expand Down
12 changes: 0 additions & 12 deletions sound/soc/codecs/wm8993.c
Original file line number Diff line number Diff line change
Expand Up @@ -1486,7 +1486,6 @@ static int wm8993_probe(struct snd_soc_codec *codec)
{
struct wm8993_priv *wm8993 = snd_soc_codec_get_drvdata(codec);
struct snd_soc_dapm_context *dapm = &codec->dapm;
int ret;

wm8993->hubs_data.hp_startup_mode = 1;
wm8993->hubs_data.dcs_codes_l = -2;
Expand Down Expand Up @@ -1518,10 +1517,6 @@ static int wm8993_probe(struct snd_soc_codec *codec)
wm8993->pdata.micbias1_lvl,
wm8993->pdata.micbias2_lvl);

ret = wm8993_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
if (ret != 0)
return ret;

snd_soc_add_codec_controls(codec, wm8993_snd_controls,
ARRAY_SIZE(wm8993_snd_controls));
if (wm8993->pdata.num_retune_configs != 0) {
Expand Down Expand Up @@ -1550,12 +1545,6 @@ static int wm8993_probe(struct snd_soc_codec *codec)

}

static int wm8993_remove(struct snd_soc_codec *codec)
{
wm8993_set_bias_level(codec, SND_SOC_BIAS_OFF);
return 0;
}

#ifdef CONFIG_PM
static int wm8993_suspend(struct snd_soc_codec *codec)
{
Expand Down Expand Up @@ -1629,7 +1618,6 @@ static const struct regmap_config wm8993_regmap = {

static struct snd_soc_codec_driver soc_codec_dev_wm8993 = {
.probe = wm8993_probe,
.remove = wm8993_remove,
.suspend = wm8993_suspend,
.resume = wm8993_resume,
.set_bias_level = wm8993_set_bias_level,
Expand Down
2 changes: 0 additions & 2 deletions sound/soc/codecs/wm8994.c
Original file line number Diff line number Diff line change
Expand Up @@ -4391,8 +4391,6 @@ static int wm8994_codec_remove(struct snd_soc_codec *codec)
struct wm8994 *control = wm8994->wm8994;
int i;

wm8994_set_bias_level(codec, SND_SOC_BIAS_OFF);

for (i = 0; i < ARRAY_SIZE(wm8994->fll_locked); i++)
wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_FLL1_LOCK + i,
&wm8994->fll_locked[i]);
Expand Down
17 changes: 7 additions & 10 deletions sound/soc/codecs/wm8995.c
Original file line number Diff line number Diff line change
Expand Up @@ -2004,7 +2004,6 @@ static int wm8995_remove(struct snd_soc_codec *codec)
int i;

wm8995 = snd_soc_codec_get_drvdata(codec);
wm8995_set_bias_level(codec, SND_SOC_BIAS_OFF);

for (i = 0; i < ARRAY_SIZE(wm8995->supplies); ++i)
regulator_unregister_notifier(wm8995->supplies[i].consumer,
Expand Down Expand Up @@ -2078,8 +2077,6 @@ static int wm8995_probe(struct snd_soc_codec *codec)
goto err_reg_enable;
}

wm8995_set_bias_level(codec, SND_SOC_BIAS_STANDBY);

/* Latch volume updates (right only; we always do left then right). */
snd_soc_update_bits(codec, WM8995_AIF1_DAC1_RIGHT_VOLUME,
WM8995_AIF1DAC1_VU_MASK, WM8995_AIF1DAC1_VU);
Expand All @@ -2102,13 +2099,6 @@ static int wm8995_probe(struct snd_soc_codec *codec)

wm8995_update_class_w(codec);

snd_soc_add_codec_controls(codec, wm8995_snd_controls,
ARRAY_SIZE(wm8995_snd_controls));
snd_soc_dapm_new_controls(&codec->dapm, wm8995_dapm_widgets,
ARRAY_SIZE(wm8995_dapm_widgets));
snd_soc_dapm_add_routes(&codec->dapm, wm8995_intercon,
ARRAY_SIZE(wm8995_intercon));

return 0;

err_reg_enable:
Expand Down Expand Up @@ -2205,6 +2195,13 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8995 = {
.remove = wm8995_remove,
.set_bias_level = wm8995_set_bias_level,
.idle_bias_off = true,

.controls = wm8995_snd_controls,
.num_controls = ARRAY_SIZE(wm8995_snd_controls),
.dapm_widgets = wm8995_dapm_widgets,
.num_dapm_widgets = ARRAY_SIZE(wm8995_dapm_widgets),
.dapm_routes = wm8995_intercon,
.num_dapm_routes = ARRAY_SIZE(wm8995_intercon),
};

static struct regmap_config wm8995_regmap = {
Expand Down
7 changes: 0 additions & 7 deletions sound/soc/codecs/wm9081.c
Original file line number Diff line number Diff line change
Expand Up @@ -1277,15 +1277,8 @@ static int wm9081_probe(struct snd_soc_codec *codec)
return 0;
}

static int wm9081_remove(struct snd_soc_codec *codec)
{
wm9081_set_bias_level(codec, SND_SOC_BIAS_OFF);
return 0;
}

static struct snd_soc_codec_driver soc_codec_dev_wm9081 = {
.probe = wm9081_probe,
.remove = wm9081_remove,

.set_sysclk = wm9081_set_sysclk,
.set_bias_level = wm9081_set_bias_level,
Expand Down

0 comments on commit f234833

Please sign in to comment.