summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/wm8962.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-11-01 15:19:23 +0000
committerMark Brown <broonie@opensource.wolfsonmicro.com>2011-11-01 18:56:21 +0000
commit2a761cde31fddfe5e22f29bc5e241d597204e095 (patch)
tree437b5c16b353945b6bbc14995155c539ac544d34 /sound/soc/codecs/wm8962.c
parent3ff51c859f086036710b375eb70a84f2efda97f9 (diff)
downloadlinux-2a761cde31fddfe5e22f29bc5e241d597204e095.tar.bz2
ASoC: Start WM8962 FLL if SYSCLK is enabled
Since we have code to automatically manage the start and stop of the FLL based on the SYSCLK widget if SYSCLK is already enabled and the FLL is configured then we need to start it up. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs/wm8962.c')
-rw-r--r--sound/soc/codecs/wm8962.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm8962.c b/sound/soc/codecs/wm8962.c
index f60dfa16545e..74ed8831990e 100644
--- a/sound/soc/codecs/wm8962.c
+++ b/sound/soc/codecs/wm8962.c
@@ -3394,6 +3394,7 @@ static int wm8962_set_fll(struct snd_soc_codec *codec, int fll_id, int source,
unsigned long timeout;
int ret;
int fll1 = snd_soc_read(codec, WM8962_FLL_CONTROL_1) & WM8962_FLL_ENA;
+ int sysclk = snd_soc_read(codec, WM8962_CLOCKING2) & WM8962_SYSCLK_ENA;
/* Any change? */
if (source == wm8962->fll_src && Fref == wm8962->fll_fref &&
@@ -3454,6 +3455,9 @@ static int wm8962_set_fll(struct snd_soc_codec *codec, int fll_id, int source,
try_wait_for_completion(&wm8962->fll_lock);
+ if (sysclk)
+ fll1 |= WM8962_FLL_ENA;
+
snd_soc_update_bits(codec, WM8962_FLL_CONTROL_1,
WM8962_FLL_FRAC | WM8962_FLL_REFCLK_SRC_MASK |
WM8962_FLL_ENA, fll1);