Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 257500
b: refs/heads/master
c: 85e9e76
h: refs/heads/master
v: v3
  • Loading branch information
Mark Brown committed Jun 6, 2011
1 parent eaf068c commit 6d41547
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cc4c670a416a36464443f465f0ddbdc9940d16dd
refs/heads/master: 85e9e766380fe40e1937b8316e8aa867544f09f1
50 changes: 40 additions & 10 deletions trunk/sound/soc/samsung/speyside.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,51 @@ static int speyside_set_bias_level(struct snd_soc_card *card,
pr_err("Failed to stop FLL\n");
return ret;
}
break;

default:
break;
}

return 0;
}

static int speyside_set_bias_level_post(struct snd_soc_card *card,
struct snd_soc_dapm_context *dapm,
enum snd_soc_bias_level level)
{
struct snd_soc_dai *codec_dai = card->rtd[0].codec_dai;
int ret;

if (dapm->dev != codec_dai->dev)
return 0;

switch (level) {
case SND_SOC_BIAS_PREPARE:
if (card->dapm.bias_level == SND_SOC_BIAS_STANDBY) {
ret = snd_soc_dai_set_pll(codec_dai, 0,
WM8915_FLL_MCLK2,
32768, 48000 * 256);
if (ret < 0) {
pr_err("Failed to start FLL\n");
return ret;
}

ret = snd_soc_dai_set_sysclk(codec_dai,
WM8915_SYSCLK_FLL,
48000 * 256,
SND_SOC_CLOCK_IN);
if (ret < 0)
return ret;
}
break;

default:
break;
}

card->dapm.bias_level = level;

return 0;
}

Expand All @@ -70,16 +110,6 @@ static int speyside_hw_params(struct snd_pcm_substream *substream,
if (ret < 0)
return ret;

ret = snd_soc_dai_set_pll(codec_dai, 0, WM8915_FLL_MCLK2,
32768, 256 * 48000);
if (ret < 0)
return ret;

ret = snd_soc_dai_set_sysclk(codec_dai, WM8915_SYSCLK_FLL,
256 * 48000, SND_SOC_CLOCK_IN);
if (ret < 0)
return ret;

return 0;
}

Expand Down

0 comments on commit 6d41547

Please sign in to comment.