ASoC: dai: Provide interface for setting DMA data at probe time
authorMark Brown <broonie@linaro.org>
Thu, 17 Oct 2013 20:13:19 +0000 (21:13 +0100)
committerMark Brown <broonie@linaro.org>
Sun, 20 Oct 2013 16:26:34 +0000 (17:26 +0100)
Allow DMA data to be set at probe time for devices that can do that,
avoiding the need to do it every time we start a stream and supporting
non-DT dmaengine users using the helpers.

Signed-off-by: Mark Brown <broonie@linaro.org>
include/sound/soc-dai.h

index ae9a227..97943fd 100644 (file)
@@ -276,6 +276,13 @@ static inline void snd_soc_dai_set_dma_data(struct snd_soc_dai *dai,
                dai->capture_dma_data = data;
 }
 
+static inline void snd_soc_dai_init_dma_data(struct snd_soc_dai *dai,
+                                            void *playback, void *capture)
+{
+       dai->playback_dma_data = playback;
+       dai->capture_dma_data = capture;
+}
+
 static inline void snd_soc_dai_set_drvdata(struct snd_soc_dai *dai,
                void *data)
 {