1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
From ae1a548ef0cb1a25242201bca5fefa5090728ea8 Mon Sep 17 00:00:00 2001
From: Matthias Reichl <hias@horus.com>
Date: Fri, 2 Feb 2018 20:30:42 +0100
Subject: [PATCH 210/454] ASoC: allo-boss-dac: fix S24_LE format
Remove set_bclk_ratio call so 24-bit data is transmitted in
24 bclk cycles.
Signed-off-by: Matthias Reichl <hias@horus.com>
---
sound/soc/bcm/allo-boss-dac.c | 20 ++------------------
1 file changed, 2 insertions(+), 18 deletions(-)
--- a/sound/soc/bcm/allo-boss-dac.c
+++ b/sound/soc/bcm/allo-boss-dac.c
@@ -222,14 +222,6 @@ static int snd_allo_boss_update_rate_den
return 0;
}
-static int snd_allo_boss_set_bclk_ratio_pro(
- struct snd_soc_dai *cpu_dai, struct snd_pcm_hw_params *params)
-{
- int bratio = snd_pcm_format_physical_width(params_format(params))
- * params_channels(params);
- return snd_soc_dai_set_bclk_ratio(cpu_dai, bratio);
-}
-
static void snd_allo_boss_gpio_mute(struct snd_soc_card *card)
{
if (mute_gpio)
@@ -281,9 +273,6 @@ static int snd_allo_boss_hw_params(
{
int ret = 0;
struct snd_soc_pcm_runtime *rtd = substream->private_data;
- struct snd_soc_dai *cpu_dai = rtd->cpu_dai;
- unsigned int sample_bits =
- snd_pcm_format_physical_width(params_format(params));
if (snd_soc_allo_boss_master) {
struct snd_soc_codec *codec = rtd->codec;
@@ -291,13 +280,8 @@ static int snd_allo_boss_hw_params(
snd_allo_boss_set_sclk(codec,
params_rate(params));
- ret = snd_allo_boss_set_bclk_ratio_pro(cpu_dai,
- params);
- if (!ret)
- ret = snd_allo_boss_update_rate_den(
- substream, params);
- } else {
- ret = snd_soc_dai_set_bclk_ratio(cpu_dai, sample_bits * 2);
+ ret = snd_allo_boss_update_rate_den(
+ substream, params);
}
return ret;
}
|