summaryrefslogtreecommitdiffstats
path: root/sound/soc/cirrus
diff options
context:
space:
mode:
authorMark Brown <broonie@linaro.org>2013-10-19 15:13:04 +0200
committerMark Brown <broonie@linaro.org>2013-10-23 13:57:12 +0200
commitd7711dc5930ced241c4f6e9b14df2a92814f9f12 (patch)
tree8b36a48c260ecbd2f67bcf5877bc1e1ab423effd /sound/soc/cirrus
parentASoC: samsung: Initialise DMA data at device probe time (diff)
downloadlinux-d7711dc5930ced241c4f6e9b14df2a92814f9f12.tar.xz
linux-d7711dc5930ced241c4f6e9b14df2a92814f9f12.zip
ASoC: ep93xx: Open code dma channel request
Currently the ep93xx DMA code is one of the few users relying on the fact that the compat code uses the dma_data as the filter data for non-DT channel requests. Since the rest of the core expects this to be a struct snd_dmaengine_dai_data this isn't terribly helpful this will be changed to use the already existing filter data so avoid breaking ep93xx by open coding the current behaviour. Signed-off-by: Mark Brown <broonie@linaro.org> Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Diffstat (limited to 'sound/soc/cirrus')
-rw-r--r--sound/soc/cirrus/ep93xx-pcm.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/sound/soc/cirrus/ep93xx-pcm.c b/sound/soc/cirrus/ep93xx-pcm.c
index 0e9f56e0d4b2..cfe517e68009 100644
--- a/sound/soc/cirrus/ep93xx-pcm.c
+++ b/sound/soc/cirrus/ep93xx-pcm.c
@@ -57,9 +57,22 @@ static bool ep93xx_pcm_dma_filter(struct dma_chan *chan, void *filter_param)
return false;
}
+static struct dma_chan *ep93xx_compat_request_channel(
+ struct snd_soc_pcm_runtime *rtd,
+ struct snd_pcm_substream *substream)
+{
+ struct snd_dmaengine_dai_dma_data *dma_data;
+
+ dma_data = snd_soc_dai_get_dma_data(rtd->cpu_dai, substream);
+
+ return snd_dmaengine_pcm_request_channel(ep93xx_pcm_dma_filter,
+ dma_data);
+}
+
static const struct snd_dmaengine_pcm_config ep93xx_dmaengine_pcm_config = {
.pcm_hardware = &ep93xx_pcm_hardware,
.compat_filter_fn = ep93xx_pcm_dma_filter,
+ .compat_request_channel = ep93xx_compat_request_channel,
.prealloc_buffer_size = 131072,
};