Commit 61100f40 authored by Sangbeom Kim's avatar Sangbeom Kim Committed by Mark Brown

ASoC: SAMSUNG: Modify I2S driver to support idma

Previously, I2S driver only can support system dma.
In this patch, i2s driver can support internal dma too.
IDMA h/w configuration is initialized on idma.c
Signed-off-by: default avatarSangbeom Kim <sbkim73@samsung.com>
Acked-by: default avatarLiam Girdwood <lrg@ti.com>
Acked-by: default avatarJassi Brar <jassisinghbrar@gmail.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 82d1d521
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
#include <plat/audio.h> #include <plat/audio.h>
#include "dma.h" #include "dma.h"
#include "idma.h"
#include "i2s.h" #include "i2s.h"
#include "i2s-regs.h" #include "i2s-regs.h"
...@@ -60,6 +61,7 @@ struct i2s_dai { ...@@ -60,6 +61,7 @@ struct i2s_dai {
/* DMA parameters */ /* DMA parameters */
struct s3c_dma_params dma_playback; struct s3c_dma_params dma_playback;
struct s3c_dma_params dma_capture; struct s3c_dma_params dma_capture;
struct s3c_dma_params idma_playback;
u32 quirks; u32 quirks;
u32 suspend_i2smod; u32 suspend_i2smod;
u32 suspend_i2scon; u32 suspend_i2scon;
...@@ -877,6 +879,10 @@ static int samsung_i2s_dai_probe(struct snd_soc_dai *dai) ...@@ -877,6 +879,10 @@ static int samsung_i2s_dai_probe(struct snd_soc_dai *dai)
if (i2s->quirks & QUIRK_NEED_RSTCLR) if (i2s->quirks & QUIRK_NEED_RSTCLR)
writel(CON_RSTCLR, i2s->addr + I2SCON); writel(CON_RSTCLR, i2s->addr + I2SCON);
if (i2s->quirks & QUIRK_SEC_DAI)
idma_reg_addr_init((void *)i2s->addr,
i2s->sec_dai->idma_playback.dma_addr);
probe_exit: probe_exit:
/* Reset any constraint on RFS and BFS */ /* Reset any constraint on RFS and BFS */
i2s->rfs = 0; i2s->rfs = 0;
...@@ -1077,6 +1083,7 @@ static __devinit int samsung_i2s_probe(struct platform_device *pdev) ...@@ -1077,6 +1083,7 @@ static __devinit int samsung_i2s_probe(struct platform_device *pdev)
sec_dai->dma_playback.dma_size = 4; sec_dai->dma_playback.dma_size = 4;
sec_dai->base = regs_base; sec_dai->base = regs_base;
sec_dai->quirks = quirks; sec_dai->quirks = quirks;
sec_dai->idma_playback.dma_addr = i2s_cfg->idma_addr;
sec_dai->pri_dai = pri_dai; sec_dai->pri_dai = pri_dai;
pri_dai->sec_dai = sec_dai; pri_dai->sec_dai = sec_dai;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment