aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/spear/spdif_in.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/spear/spdif_in.c')
-rw-r--r--sound/soc/spear/spdif_in.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/sound/soc/spear/spdif_in.c b/sound/soc/spear/spdif_in.c
index 4627110f3441..4ab442a63d7e 100644
--- a/sound/soc/spear/spdif_in.c
+++ b/sound/soc/spear/spdif_in.c
@@ -18,6 +18,7 @@
18#include <linux/ioport.h> 18#include <linux/ioport.h>
19#include <linux/module.h> 19#include <linux/module.h>
20#include <linux/platform_device.h> 20#include <linux/platform_device.h>
21#include <sound/dmaengine_pcm.h>
21#include <sound/pcm.h> 22#include <sound/pcm.h>
22#include <sound/pcm_params.h> 23#include <sound/pcm_params.h>
23#include <sound/soc.h> 24#include <sound/soc.h>
@@ -38,6 +39,8 @@ struct spdif_in_dev {
38 struct device *dev; 39 struct device *dev;
39 void (*reset_perip)(void); 40 void (*reset_perip)(void);
40 int irq; 41 int irq;
42 struct snd_dmaengine_dai_dma_data dma_params_rx;
43 struct snd_dmaengine_pcm_config config;
41}; 44};
42 45
43static void spdif_in_configure(struct spdif_in_dev *host) 46static void spdif_in_configure(struct spdif_in_dev *host)
@@ -54,7 +57,8 @@ static int spdif_in_dai_probe(struct snd_soc_dai *dai)
54{ 57{
55 struct spdif_in_dev *host = snd_soc_dai_get_drvdata(dai); 58 struct spdif_in_dev *host = snd_soc_dai_get_drvdata(dai);
56 59
57 dai->capture_dma_data = &host->dma_params; 60 host->dma_params_rx.filter_data = &host->dma_params;
61 dai->capture_dma_data = &host->dma_params_rx;
58 62
59 return 0; 63 return 0;
60} 64}
@@ -245,7 +249,6 @@ static int spdif_in_probe(struct platform_device *pdev)
245 host->dma_params.addr = res_fifo->start; 249 host->dma_params.addr = res_fifo->start;
246 host->dma_params.max_burst = 16; 250 host->dma_params.max_burst = 16;
247 host->dma_params.addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES; 251 host->dma_params.addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES;
248 host->dma_params.filter = pdata->filter;
249 host->reset_perip = pdata->reset_perip; 252 host->reset_perip = pdata->reset_perip;
250 253
251 host->dev = &pdev->dev; 254 host->dev = &pdev->dev;
@@ -263,7 +266,8 @@ static int spdif_in_probe(struct platform_device *pdev)
263 if (ret) 266 if (ret)
264 return ret; 267 return ret;
265 268
266 return devm_spear_pcm_platform_register(&pdev->dev); 269 return devm_spear_pcm_platform_register(&pdev->dev, &host->config,
270 pdata->filter);
267} 271}
268 272
269static struct platform_driver spdif_in_driver = { 273static struct platform_driver spdif_in_driver = {