diff options
Diffstat (limited to 'sound/soc/blackfin/bf5xx-ad1938.c')
-rw-r--r-- | sound/soc/blackfin/bf5xx-ad1938.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/sound/soc/blackfin/bf5xx-ad1938.c b/sound/soc/blackfin/bf5xx-ad1938.c index 08269e91810c..2ef1e5013b8c 100644 --- a/sound/soc/blackfin/bf5xx-ad1938.c +++ b/sound/soc/blackfin/bf5xx-ad1938.c | |||
@@ -61,6 +61,7 @@ static int bf5xx_ad1938_hw_params(struct snd_pcm_substream *substream, | |||
61 | struct snd_soc_pcm_runtime *rtd = substream->private_data; | 61 | struct snd_soc_pcm_runtime *rtd = substream->private_data; |
62 | struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai; | 62 | struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai; |
63 | struct snd_soc_dai *codec_dai = rtd->dai->codec_dai; | 63 | struct snd_soc_dai *codec_dai = rtd->dai->codec_dai; |
64 | unsigned int channel_map[] = {0, 1, 2, 3, 4, 5, 6, 7}; | ||
64 | int ret = 0; | 65 | int ret = 0; |
65 | /* set cpu DAI configuration */ | 66 | /* set cpu DAI configuration */ |
66 | ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_DSP_A | | 67 | ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_DSP_A | |
@@ -75,7 +76,13 @@ static int bf5xx_ad1938_hw_params(struct snd_pcm_substream *substream, | |||
75 | return ret; | 76 | return ret; |
76 | 77 | ||
77 | /* set codec DAI slots, 8 channels, all channels are enabled */ | 78 | /* set codec DAI slots, 8 channels, all channels are enabled */ |
78 | ret = snd_soc_dai_set_tdm_slot(codec_dai, 0xFF, 8); | 79 | ret = snd_soc_dai_set_tdm_slot(codec_dai, 0xFF, 0xFF, 8, 32); |
80 | if (ret < 0) | ||
81 | return ret; | ||
82 | |||
83 | /* set cpu DAI channel mapping */ | ||
84 | ret = snd_soc_dai_set_channel_map(cpu_dai, ARRAY_SIZE(channel_map), | ||
85 | channel_map, ARRAY_SIZE(channel_map), channel_map); | ||
79 | if (ret < 0) | 86 | if (ret < 0) |
80 | return ret; | 87 | return ret; |
81 | 88 | ||