diff options
author | Paul Handrigan <Paul.Handrigan@cirrus.com> | 2013-03-05 23:12:56 +0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-03-06 08:51:30 +0400 |
commit | cadf2120ff756789a3adaac07c5b85a09649c66e (patch) | |
tree | 4911c159f1ca318f95623366c543ea8c870cab5f /sound/soc/codecs/cs42l73.c | |
parent | 6dbe51c251a327e012439c4772097a13df43c5b8 (diff) | |
download | linux-cadf2120ff756789a3adaac07c5b85a09649c66e.tar.xz |
ASoC: cs42l73: If Internal MCLK is >= 6.4MHz, then set SCLK to 64*Fs.
Signed-off-by: Paul Handrigan <Paul.Handrigan@cirrus.com>
Acked-by: Brian Austin <brian.austin@cirrus.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs/cs42l73.c')
-rw-r--r-- | sound/soc/codecs/cs42l73.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/soc/codecs/cs42l73.c b/sound/soc/codecs/cs42l73.c index 6361dab48bd1..3b20c86cdb01 100644 --- a/sound/soc/codecs/cs42l73.c +++ b/sound/soc/codecs/cs42l73.c @@ -1180,7 +1180,11 @@ static int cs42l73_pcm_hw_params(struct snd_pcm_substream *substream, priv->config[id].mmcc &= 0xC0; priv->config[id].mmcc |= cs42l73_mclk_coeffs[mclk_coeff].mmcc; priv->config[id].spc &= 0xFC; - priv->config[id].spc |= MCK_SCLK_MCLK; + /* Use SCLK=64*Fs if internal MCLK >= 6.4MHz */ + if (priv->mclk >= 6400000) + priv->config[id].spc |= MCK_SCLK_64FS; + else + priv->config[id].spc |= MCK_SCLK_MCLK; } else { /* CS42L73 Slave */ priv->config[id].spc &= 0xFC; |