From: Mark Brown Date: Tue, 17 Jan 2012 16:28:59 +0000 (+0000) Subject: ASoC: Wait for WM8993 FLL to stabilise X-Git-Tag: upstream/snapshot3+hdmi~8282^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=986b2f2c21b308e21160a40359b81370f8fee6ec;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git ASoC: Wait for WM8993 FLL to stabilise Ensure the FLL is locked before we return from set_fll(). Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/wm8993.c b/sound/soc/codecs/wm8993.c index 2b40c93..7c7fd92 100644 --- a/sound/soc/codecs/wm8993.c +++ b/sound/soc/codecs/wm8993.c @@ -444,6 +444,12 @@ static int _wm8993_set_fll(struct snd_soc_codec *codec, int fll_id, int source, /* Enable the FLL */ snd_soc_write(codec, WM8993_FLL_CONTROL_1, reg1 | WM8993_FLL_ENA); + /* Both overestimates */ + if (Fref < 1000000) + msleep(3); + else + msleep(1); + dev_dbg(codec->dev, "FLL enabled at %dHz->%dHz\n", Fref, Fout); wm8993->fll_fref = Fref;