summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/rl6231.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2015-11-27 13:40:20 +0100
committerTakashi Iwai <tiwai@suse.de>2015-11-27 13:40:20 +0100
commit06a691e64b11323a735db3c3bd909d3c0712698f (patch)
treee60b5a230fc2ea6e0f514d878d322a1f8e101c57 /sound/soc/codecs/rl6231.c
parentALSA: hda - Fix noise on Gigabyte Z170X mobo (diff)
parentMerge remote-tracking branches 'asoc/fix/rt5677', 'asoc/fix/st', 'asoc/fix/su... (diff)
downloadlinux-06a691e64b11323a735db3c3bd909d3c0712698f.tar.xz
linux-06a691e64b11323a735db3c3bd909d3c0712698f.zip
Merge tag 'asoc-fix-v4.4-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v4.4 Quite a large batch of fixes have come in since the merge window, mainly driver specific ones but there's a couple of core ones: - A fix for DAPM resume on active streams to ensure everything ends up cleanly in the right state. - Reset the DAPM cache when freeing widgets to fix a crash on driver remove and reload. The PM functions for nau8825 are new code which fix crashes on resume.
Diffstat (limited to 'sound/soc/codecs/rl6231.c')
-rw-r--r--sound/soc/codecs/rl6231.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/soc/codecs/rl6231.c b/sound/soc/codecs/rl6231.c
index aca479fa7670..1dc68ab08a17 100644
--- a/sound/soc/codecs/rl6231.c
+++ b/sound/soc/codecs/rl6231.c
@@ -80,8 +80,10 @@ int rl6231_calc_dmic_clk(int rate)
}
for (i = 0; i < ARRAY_SIZE(div); i++) {
- /* find divider that gives DMIC frequency below 3MHz */
- if (3000000 * div[i] >= rate)
+ if ((div[i] % 3) == 0)
+ continue;
+ /* find divider that gives DMIC frequency below 3.072MHz */
+ if (3072000 * div[i] >= rate)
return i;
}