summaryrefslogtreecommitdiff
path: root/sound/soc/at91/at91rm9200-i2s.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/at91/at91rm9200-i2s.c')
-rw-r--r--sound/soc/at91/at91rm9200-i2s.c52
1 files changed, 40 insertions, 12 deletions
diff --git a/sound/soc/at91/at91rm9200-i2s.c b/sound/soc/at91/at91rm9200-i2s.c
index 044a774b4301..91f1daa44f19 100644
--- a/sound/soc/at91/at91rm9200-i2s.c
+++ b/sound/soc/at91/at91rm9200-i2s.c
@@ -51,24 +51,52 @@
static struct snd_soc_dai_mode at91rm9200_i2s[] = {
/* 8k: BCLK = (MCLK/10) = (60MHz/50) = 1.2MHz */
- { AT91RM9200_I2S_DAIFMT, SND_SOC_DAITDM_LRDW(0,0),
- SNDRV_PCM_FMTBIT_S16_LE, SNDRV_PCM_RATE_8000, AT91RM9200_I2S_DIR,
- SND_SOC_DAI_BFS_DIV, 1500, SND_SOC_FSBD(10), (25 << 16 | 74) },
+ {
+ .fmt = AT91RM9200_I2S_DAIFMT,
+ .pcmfmt = SNDRV_PCM_FMTBIT_S16_LE,
+ .pcmrate = SNDRV_PCM_RATE_8000,
+ .pcmdir = AT91RM9200_I2S_DIR,
+ .flags = SND_SOC_DAI_BFS_DIV,
+ .fs = 1500,
+ .bfs = SND_SOC_FSBD(10),
+ .priv = (25 << 16 | 74),
+ },
/* 16k: BCLK = (MCLK/3) ~= (60MHz/14) = 4.285714MHz */
- { AT91RM9200_I2S_DAIFMT, SND_SOC_DAITDM_LRDW(0,0),
- SNDRV_PCM_FMTBIT_S16_LE, SNDRV_PCM_RATE_16000, AT91RM9200_I2S_DIR,
- SND_SOC_DAI_BFS_DIV, 750, SND_SOC_FSBD(3) , (7 << 16 | 133) },
+ {
+ .fmt = AT91RM9200_I2S_DAIFMT,
+ .pcmfmt = SNDRV_PCM_FMTBIT_S16_LE,
+ .pcmrate = SNDRV_PCM_RATE_16000,
+ .pcmdir = AT91RM9200_I2S_DIR,
+ .flags = SND_SOC_DAI_BFS_DIV,
+ .fs = 750,
+ .bfs = SND_SOC_FSBD(3),
+ .flags (7 << 16 | 133),
+ },
/* 24k: BCLK = (MCLK/10) = (60MHz/50) = 1.2MHz */
- { AT91RM9200_I2S_DAIFMT, SND_SOC_DAITDM_LRDW(0,0),
- SNDRV_PCM_FMTBIT_S16_LE, SNDRV_PCM_RATE_22050, AT91RM9200_I2S_DIR,
- SND_SOC_DAI_BFS_DIV, 500, SND_SOC_FSBD(10), (25 << 16 | 24) },
+ {
+ .fmt = AT91RM9200_I2S_DAIFMT,
+ .pcmfmt = SNDRV_PCM_FMTBIT_S16_LE,
+ .pcmrate = SNDRV_PCM_RATE_22050,
+ .pcmdir = AT91RM9200_I2S_DIR,
+ .flags = SND_SOC_DAI_BFS_DIV,
+ .fs = 500,
+ .bfs = SND_SOC_FSBD(10),
+ .priv = (25 << 16 | 24),
+ },
/* 48kHz: BCLK = (MCLK/5) ~= (60MHz/26) = 2.3076923MHz */
- { AT91RM9200_I2S_DAIFMT, SND_SOC_DAITDM_LRDW(0,0),
- SNDRV_PCM_FMTBIT_S16_LE, SNDRV_PCM_RATE_48000, AT91RM9200_I2S_DIR,
- SND_SOC_DAI_BFS_DIV, 250, SND_SOC_FSBD(5), (13 << 16 | 23) },
+ {
+ .fmt = AT91RM9200_I2S_DAIFMT,
+ .pcmfmt = SNDRV_PCM_FMTBIT_S16_LE,
+ .pcmrate = SNDRV_PCM_RATE_48000,
+ .pcmdir = AT91RM9200_I2S_DIR,
+ .flags = SND_SOC_DAI_BFS_DIV,
+ .fs = 250,
+ .bfs SND_SOC_FSBD(5),
+ .priv = (13 << 16 | 23),
+ },
};