diff options
Diffstat (limited to 'sound/soc/atmel/sam9g20_wm8731.c')
-rw-r--r-- | sound/soc/atmel/sam9g20_wm8731.c | 31 |
1 files changed, 2 insertions, 29 deletions
diff --git a/sound/soc/atmel/sam9g20_wm8731.c b/sound/soc/atmel/sam9g20_wm8731.c index 66b66d0e7514..f5ad214663f9 100644 --- a/sound/soc/atmel/sam9g20_wm8731.c +++ b/sound/soc/atmel/sam9g20_wm8731.c | |||
@@ -47,7 +47,6 @@ | |||
47 | #include <sound/soc.h> | 47 | #include <sound/soc.h> |
48 | 48 | ||
49 | #include <asm/mach-types.h> | 49 | #include <asm/mach-types.h> |
50 | #include <mach/hardware.h> | ||
51 | 50 | ||
52 | #include "../codecs/wm8731.h" | 51 | #include "../codecs/wm8731.h" |
53 | #include "atmel-pcm.h" | 52 | #include "atmel-pcm.h" |
@@ -64,33 +63,6 @@ | |||
64 | 63 | ||
65 | static struct clk *mclk; | 64 | static struct clk *mclk; |
66 | 65 | ||
67 | static int at91sam9g20ek_hw_params(struct snd_pcm_substream *substream, | ||
68 | struct snd_pcm_hw_params *params) | ||
69 | { | ||
70 | struct snd_soc_pcm_runtime *rtd = substream->private_data; | ||
71 | struct snd_soc_dai *codec_dai = rtd->codec_dai; | ||
72 | struct snd_soc_dai *cpu_dai = rtd->cpu_dai; | ||
73 | int ret; | ||
74 | |||
75 | /* set codec DAI configuration */ | ||
76 | ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S | | ||
77 | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); | ||
78 | if (ret < 0) | ||
79 | return ret; | ||
80 | |||
81 | /* set cpu DAI configuration */ | ||
82 | ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S | | ||
83 | SND_SOC_DAIFMT_NB_NF | SND_SOC_DAIFMT_CBM_CFM); | ||
84 | if (ret < 0) | ||
85 | return ret; | ||
86 | |||
87 | return 0; | ||
88 | } | ||
89 | |||
90 | static struct snd_soc_ops at91sam9g20ek_ops = { | ||
91 | .hw_params = at91sam9g20ek_hw_params, | ||
92 | }; | ||
93 | |||
94 | static int at91sam9g20ek_set_bias_level(struct snd_soc_card *card, | 66 | static int at91sam9g20ek_set_bias_level(struct snd_soc_card *card, |
95 | struct snd_soc_dapm_context *dapm, | 67 | struct snd_soc_dapm_context *dapm, |
96 | enum snd_soc_bias_level level) | 68 | enum snd_soc_bias_level level) |
@@ -173,7 +145,8 @@ static struct snd_soc_dai_link at91sam9g20ek_dai = { | |||
173 | .init = at91sam9g20ek_wm8731_init, | 145 | .init = at91sam9g20ek_wm8731_init, |
174 | .platform_name = "at91rm9200_ssc.0", | 146 | .platform_name = "at91rm9200_ssc.0", |
175 | .codec_name = "wm8731.0-001b", | 147 | .codec_name = "wm8731.0-001b", |
176 | .ops = &at91sam9g20ek_ops, | 148 | .dai_fmt = SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF | |
149 | SND_SOC_DAIFMT_CBM_CFM, | ||
177 | }; | 150 | }; |
178 | 151 | ||
179 | static struct snd_soc_card snd_soc_at91sam9g20ek = { | 152 | static struct snd_soc_card snd_soc_at91sam9g20ek = { |