diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-04-18 10:24:31 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-04-18 10:24:31 -0400 |
commit | 8dd2b66d1a961231685a3bfe5937c85d846fbf5d (patch) | |
tree | 8117553488bf4ef09b048a4b343cf37cc16bf46d /sound/soc/fsl/imx-ssi.c | |
parent | 126825e7ea271ae8e3172e10ca1fc22c908b5385 (diff) | |
parent | 24568ea4bef5ab8106206eddf5512434421c00ed (diff) |
Merge tag 'asoc-v3.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: More updates for v3.10
The main additional change here is Lars-Peter's DMA work plus the
platform conversions which have been tested - getting this in mainline
will make life easier for development after the merge window. These
factor a large chunk of code out of the drivers for the platforms using
dmaengine, greatly simplifying development.
Diffstat (limited to 'sound/soc/fsl/imx-ssi.c')
-rw-r--r-- | sound/soc/fsl/imx-ssi.c | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/sound/soc/fsl/imx-ssi.c b/sound/soc/fsl/imx-ssi.c index 4ce2d608b37a..902fab02b851 100644 --- a/sound/soc/fsl/imx-ssi.c +++ b/sound/soc/fsl/imx-ssi.c | |||
@@ -232,23 +232,6 @@ static int imx_ssi_set_dai_clkdiv(struct snd_soc_dai *cpu_dai, | |||
232 | return 0; | 232 | return 0; |
233 | } | 233 | } |
234 | 234 | ||
235 | static int imx_ssi_startup(struct snd_pcm_substream *substream, | ||
236 | struct snd_soc_dai *cpu_dai) | ||
237 | { | ||
238 | struct imx_ssi *ssi = snd_soc_dai_get_drvdata(cpu_dai); | ||
239 | struct snd_dmaengine_dai_dma_data *dma_data; | ||
240 | |||
241 | /* Tx/Rx config */ | ||
242 | if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) | ||
243 | dma_data = &ssi->dma_params_tx; | ||
244 | else | ||
245 | dma_data = &ssi->dma_params_rx; | ||
246 | |||
247 | snd_soc_dai_set_dma_data(cpu_dai, substream, dma_data); | ||
248 | |||
249 | return 0; | ||
250 | } | ||
251 | |||
252 | /* | 235 | /* |
253 | * Should only be called when port is inactive (i.e. SSIEN = 0), | 236 | * Should only be called when port is inactive (i.e. SSIEN = 0), |
254 | * although can be called multiple times by upper layers. | 237 | * although can be called multiple times by upper layers. |
@@ -353,7 +336,6 @@ static int imx_ssi_trigger(struct snd_pcm_substream *substream, int cmd, | |||
353 | } | 336 | } |
354 | 337 | ||
355 | static const struct snd_soc_dai_ops imx_ssi_pcm_dai_ops = { | 338 | static const struct snd_soc_dai_ops imx_ssi_pcm_dai_ops = { |
356 | .startup = imx_ssi_startup, | ||
357 | .hw_params = imx_ssi_hw_params, | 339 | .hw_params = imx_ssi_hw_params, |
358 | .set_fmt = imx_ssi_set_dai_fmt, | 340 | .set_fmt = imx_ssi_set_dai_fmt, |
359 | .set_clkdiv = imx_ssi_set_dai_clkdiv, | 341 | .set_clkdiv = imx_ssi_set_dai_clkdiv, |
@@ -373,6 +355,10 @@ static int imx_ssi_dai_probe(struct snd_soc_dai *dai) | |||
373 | SSI_SFCSR_RFWM0(ssi->dma_params_rx.maxburst); | 355 | SSI_SFCSR_RFWM0(ssi->dma_params_rx.maxburst); |
374 | writel(val, ssi->base + SSI_SFCSR); | 356 | writel(val, ssi->base + SSI_SFCSR); |
375 | 357 | ||
358 | /* Tx/Rx config */ | ||
359 | dai->playback_dma_data = &ssi->dma_params_tx; | ||
360 | dai->capture_dma_data = &ssi->dma_params_rx; | ||
361 | |||
376 | return 0; | 362 | return 0; |
377 | } | 363 | } |
378 | 364 | ||