]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/3.10.96/asoc-arizona-fix-bclk-for-sample-rates-that-are-multiple-of-4khz.patch
4.14-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 3.10.96 / asoc-arizona-fix-bclk-for-sample-rates-that-are-multiple-of-4khz.patch
CommitLineData
2425ddcb
GKH
1From e73694d871867cae8471d2350ce89acb38bc2b63 Mon Sep 17 00:00:00 2001
2From: Nikesh Oswal <Nikesh.Oswal@cirrus.com>
3Date: Wed, 23 Dec 2015 14:18:05 +0000
4Subject: ASoC: arizona: Fix bclk for sample rates that are multiple of 4kHz
5
6From: Nikesh Oswal <Nikesh.Oswal@cirrus.com>
7
8commit e73694d871867cae8471d2350ce89acb38bc2b63 upstream.
9
10For a sample rate of 12kHz the bclk was taken from the 44.1kHz table as
11we test for a multiple of 8kHz. This patch fixes this issue by testing
12for multiples of 4kHz instead.
13
14Signed-off-by: Nikesh Oswal <Nikesh.Oswal@cirrus.com>
15Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
16Signed-off-by: Mark Brown <broonie@kernel.org>
17Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
18
19---
20 sound/soc/codecs/arizona.c | 2 +-
21 1 file changed, 1 insertion(+), 1 deletion(-)
22
23--- a/sound/soc/codecs/arizona.c
24+++ b/sound/soc/codecs/arizona.c
25@@ -1057,7 +1057,7 @@ static int arizona_hw_params(struct snd_
26 int chan_limit = arizona->pdata.max_channels_clocked[dai->id - 1];
27 int bclk, lrclk, wl, frame, bclk_target;
28
29- if (params_rate(params) % 8000)
30+ if (params_rate(params) % 4000)
31 rates = &arizona_44k1_bclk_rates[0];
32 else
33 rates = &arizona_48k_bclk_rates[0];