Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Bard Liao <bardliao@realtek.com>
To: broonie@kernel.org, lgirdwood@gmail.com
Cc: oder_chiou@realtek.com, alsa-devel@alsa-project.org,
	lars@metafoo.de, koro.chen@mediatek.com, john.lin@realtek.com,
	Bard Liao <bardliao@realtek.com>,
	flove@realtek.com
Subject: [PATCH 1/2] ASoC: rt5677: fixed wrong DMIC ref clock
Date: Tue, 28 Apr 2015 11:27:39 +0800	[thread overview]
Message-ID: <1430191660-2959-1-git-send-email-bardliao@realtek.com> (raw)

DMIC clock source is not from codec system clock directly. it is
generated from the division of system clock. And it should be 256 *
sample rate of AIF1.

Signed-off-by: Bard Liao <bardliao@realtek.com>
---
 sound/soc/codecs/rt5677.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/codecs/rt5677.c b/sound/soc/codecs/rt5677.c
index fbe16ba..dca64ae 100644
--- a/sound/soc/codecs/rt5677.c
+++ b/sound/soc/codecs/rt5677.c
@@ -917,7 +917,7 @@ static int set_dmic_clk(struct snd_soc_dapm_widget *w,
 {
 	struct snd_soc_codec *codec = snd_soc_dapm_to_codec(w->dapm);
 	struct rt5677_priv *rt5677 = snd_soc_codec_get_drvdata(codec);
-	int idx = rl6231_calc_dmic_clk(rt5677->sysclk);
+	int idx = rl6231_calc_dmic_clk(rt5677->lrck[RT5677_AIF1] << 8);
 
 	if (idx < 0)
 		dev_err(codec->dev, "Failed to set DMIC clock\n");
-- 
1.8.1.1.439.g50a6b54

             reply	other threads:[~2015-04-28  3:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-28  3:27 Bard Liao [this message]
2015-04-28  3:27 ` [PATCH 2/2] ASoC: rt5677: add i2s asrc clk src selection Bard Liao
2015-04-29 11:20   ` Mark Brown
2015-04-29 11:20 ` [PATCH 1/2] ASoC: rt5677: fixed wrong DMIC ref clock Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1430191660-2959-1-git-send-email-bardliao@realtek.com \
    --to=bardliao@realtek.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=flove@realtek.com \
    --cc=john.lin@realtek.com \
    --cc=koro.chen@mediatek.com \
    --cc=lars@metafoo.de \
    --cc=lgirdwood@gmail.com \
    --cc=oder_chiou@realtek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox