aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/omap
diff options
context:
space:
mode:
authorLiam Girdwood <lg@opensource.wolfsonmicro.com>2008-07-07 11:08:07 -0400
committerJaroslav Kysela <perex@perex.cz>2008-07-10 03:32:41 -0400
commit8687eb8bded8c3c5842a85bd0c30e43fc5a3e0e0 (patch)
tree11fa0cdcba39f697e2849c20d5d125d5e738aab6 /sound/soc/omap
parent8cf7b2b393b26b9ba1ccbeeb271a88e51d58f3e3 (diff)
ALSA: asoc: omap - merge structs snd_soc_codec_dai and snd_soc_cpu_dai.
This patch merges struct snd_soc_codec_dai and struct snd_soc_cpu_dai into struct snd_soc_dai for the Omap platform. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Diffstat (limited to 'sound/soc/omap')
-rw-r--r--sound/soc/omap/n810.c4
-rw-r--r--sound/soc/omap/omap-mcbsp.c16
-rw-r--r--sound/soc/omap/omap-mcbsp.h2
-rw-r--r--sound/soc/omap/omap-pcm.c2
4 files changed, 12 insertions, 12 deletions
diff --git a/sound/soc/omap/n810.c b/sound/soc/omap/n810.c
index 74f4599b4d7e..d1233c01398f 100644
--- a/sound/soc/omap/n810.c
+++ b/sound/soc/omap/n810.c
@@ -86,8 +86,8 @@ static int n810_hw_params(struct snd_pcm_substream *substream,
86 struct snd_pcm_hw_params *params) 86 struct snd_pcm_hw_params *params)
87{ 87{
88 struct snd_soc_pcm_runtime *rtd = substream->private_data; 88 struct snd_soc_pcm_runtime *rtd = substream->private_data;
89 struct snd_soc_codec_dai *codec_dai = rtd->dai->codec_dai; 89 struct snd_soc_dai *codec_dai = rtd->dai->codec_dai;
90 struct snd_soc_cpu_dai *cpu_dai = rtd->dai->cpu_dai; 90 struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai;
91 int err; 91 int err;
92 92
93 /* Set codec DAI configuration */ 93 /* Set codec DAI configuration */
diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index 40d87e6d0de8..00b0c9d73cd4 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -103,7 +103,7 @@ static const unsigned long omap2420_mcbsp_port[][2] = {};
103static int omap_mcbsp_dai_startup(struct snd_pcm_substream *substream) 103static int omap_mcbsp_dai_startup(struct snd_pcm_substream *substream)
104{ 104{
105 struct snd_soc_pcm_runtime *rtd = substream->private_data; 105 struct snd_soc_pcm_runtime *rtd = substream->private_data;
106 struct snd_soc_cpu_dai *cpu_dai = rtd->dai->cpu_dai; 106 struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai;
107 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 107 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
108 int err = 0; 108 int err = 0;
109 109
@@ -116,7 +116,7 @@ static int omap_mcbsp_dai_startup(struct snd_pcm_substream *substream)
116static void omap_mcbsp_dai_shutdown(struct snd_pcm_substream *substream) 116static void omap_mcbsp_dai_shutdown(struct snd_pcm_substream *substream)
117{ 117{
118 struct snd_soc_pcm_runtime *rtd = substream->private_data; 118 struct snd_soc_pcm_runtime *rtd = substream->private_data;
119 struct snd_soc_cpu_dai *cpu_dai = rtd->dai->cpu_dai; 119 struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai;
120 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 120 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
121 121
122 if (!cpu_dai->active) { 122 if (!cpu_dai->active) {
@@ -128,7 +128,7 @@ static void omap_mcbsp_dai_shutdown(struct snd_pcm_substream *substream)
128static int omap_mcbsp_dai_trigger(struct snd_pcm_substream *substream, int cmd) 128static int omap_mcbsp_dai_trigger(struct snd_pcm_substream *substream, int cmd)
129{ 129{
130 struct snd_soc_pcm_runtime *rtd = substream->private_data; 130 struct snd_soc_pcm_runtime *rtd = substream->private_data;
131 struct snd_soc_cpu_dai *cpu_dai = rtd->dai->cpu_dai; 131 struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai;
132 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 132 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
133 int err = 0; 133 int err = 0;
134 134
@@ -157,7 +157,7 @@ static int omap_mcbsp_dai_hw_params(struct snd_pcm_substream *substream,
157 struct snd_pcm_hw_params *params) 157 struct snd_pcm_hw_params *params)
158{ 158{
159 struct snd_soc_pcm_runtime *rtd = substream->private_data; 159 struct snd_soc_pcm_runtime *rtd = substream->private_data;
160 struct snd_soc_cpu_dai *cpu_dai = rtd->dai->cpu_dai; 160 struct snd_soc_dai *cpu_dai = rtd->dai->cpu_dai;
161 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 161 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
162 struct omap_mcbsp_reg_cfg *regs = &mcbsp_data->regs; 162 struct omap_mcbsp_reg_cfg *regs = &mcbsp_data->regs;
163 int dma, bus_id = mcbsp_data->bus_id, id = cpu_dai->id; 163 int dma, bus_id = mcbsp_data->bus_id, id = cpu_dai->id;
@@ -223,7 +223,7 @@ static int omap_mcbsp_dai_hw_params(struct snd_pcm_substream *substream,
223 * This must be called before _set_clkdiv and _set_sysclk since McBSP register 223 * This must be called before _set_clkdiv and _set_sysclk since McBSP register
224 * cache is initialized here 224 * cache is initialized here
225 */ 225 */
226static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_cpu_dai *cpu_dai, 226static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai,
227 unsigned int fmt) 227 unsigned int fmt)
228{ 228{
229 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 229 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
@@ -292,7 +292,7 @@ static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_cpu_dai *cpu_dai,
292 return 0; 292 return 0;
293} 293}
294 294
295static int omap_mcbsp_dai_set_clkdiv(struct snd_soc_cpu_dai *cpu_dai, 295static int omap_mcbsp_dai_set_clkdiv(struct snd_soc_dai *cpu_dai,
296 int div_id, int div) 296 int div_id, int div)
297{ 297{
298 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); 298 struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data);
@@ -347,7 +347,7 @@ static int omap_mcbsp_dai_set_clks_src(struct omap_mcbsp_data *mcbsp_data,
347 return 0; 347 return 0;
348} 348}
349 349
350static int omap_mcbsp_dai_set_dai_sysclk(struct snd_soc_cpu_dai *cpu_dai, 350static int omap_mcbsp_dai_set_dai_sysclk(struct snd_soc_dai *cpu_dai,
351 int clk_id, unsigned int freq, 351 int clk_id, unsigned int freq,
352 int dir) 352 int dir)
353{ 353{
@@ -376,7 +376,7 @@ static int omap_mcbsp_dai_set_dai_sysclk(struct snd_soc_cpu_dai *cpu_dai,
376 return err; 376 return err;
377} 377}
378 378
379struct snd_soc_cpu_dai omap_mcbsp_dai[NUM_LINKS] = { 379struct snd_soc_dai omap_mcbsp_dai[NUM_LINKS] = {
380{ 380{
381 .name = "omap-mcbsp-dai", 381 .name = "omap-mcbsp-dai",
382 .id = 0, 382 .id = 0,
diff --git a/sound/soc/omap/omap-mcbsp.h b/sound/soc/omap/omap-mcbsp.h
index 9965fd4b0427..ed8afb550671 100644
--- a/sound/soc/omap/omap-mcbsp.h
+++ b/sound/soc/omap/omap-mcbsp.h
@@ -44,6 +44,6 @@ enum omap_mcbsp_div {
44 */ 44 */
45#define NUM_LINKS 1 45#define NUM_LINKS 1
46 46
47extern struct snd_soc_cpu_dai omap_mcbsp_dai[NUM_LINKS]; 47extern struct snd_soc_dai omap_mcbsp_dai[NUM_LINKS];
48 48
49#endif 49#endif
diff --git a/sound/soc/omap/omap-pcm.c b/sound/soc/omap/omap-pcm.c
index 62370202c649..e092f3d836d0 100644
--- a/sound/soc/omap/omap-pcm.c
+++ b/sound/soc/omap/omap-pcm.c
@@ -316,7 +316,7 @@ static void omap_pcm_free_dma_buffers(struct snd_pcm *pcm)
316 } 316 }
317} 317}
318 318
319int omap_pcm_new(struct snd_card *card, struct snd_soc_codec_dai *dai, 319int omap_pcm_new(struct snd_card *card, struct snd_soc_dai *dai,
320 struct snd_pcm *pcm) 320 struct snd_pcm *pcm)
321{ 321{
322 int ret = 0; 322 int ret = 0;