aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/wm9081.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-03-07 15:59:45 -0500
committerMark Brown <broonie@opensource.wolfsonmicro.com>2011-03-08 13:56:22 -0500
commit63d24b79b66ea5d5b04dadb9e92f31c0141948fb (patch)
tree81af70e982ada3e72d1a773aa7d8cb86792dcc9d /sound/soc/codecs/wm9081.c
parentec4ee52a8f5fb5b8e235ae9f02589d60d54740cc (diff)
ASoC: Convert WM9081 SYSCLK configuration to be device wide
Also respace the CODEC ops a bit for legibility. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
Diffstat (limited to 'sound/soc/codecs/wm9081.c')
-rw-r--r--sound/soc/codecs/wm9081.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sound/soc/codecs/wm9081.c b/sound/soc/codecs/wm9081.c
index 8b1b2c9ab59e..effaf75cacc8 100644
--- a/sound/soc/codecs/wm9081.c
+++ b/sound/soc/codecs/wm9081.c
@@ -1140,10 +1140,9 @@ static int wm9081_digital_mute(struct snd_soc_dai *codec_dai, int mute)
1140 return 0; 1140 return 0;
1141} 1141}
1142 1142
1143static int wm9081_set_sysclk(struct snd_soc_dai *codec_dai, 1143static int wm9081_set_sysclk(struct snd_soc_codec *codec,
1144 int clk_id, unsigned int freq, int dir) 1144 int clk_id, unsigned int freq, int dir)
1145{ 1145{
1146 struct snd_soc_codec *codec = codec_dai->codec;
1147 struct wm9081_priv *wm9081 = snd_soc_codec_get_drvdata(codec); 1146 struct wm9081_priv *wm9081 = snd_soc_codec_get_drvdata(codec);
1148 1147
1149 switch (clk_id) { 1148 switch (clk_id) {
@@ -1208,7 +1207,6 @@ static int wm9081_set_tdm_slot(struct snd_soc_dai *dai,
1208 1207
1209static struct snd_soc_dai_ops wm9081_dai_ops = { 1208static struct snd_soc_dai_ops wm9081_dai_ops = {
1210 .hw_params = wm9081_hw_params, 1209 .hw_params = wm9081_hw_params,
1211 .set_sysclk = wm9081_set_sysclk,
1212 .set_fmt = wm9081_set_dai_fmt, 1210 .set_fmt = wm9081_set_dai_fmt,
1213 .digital_mute = wm9081_digital_mute, 1211 .digital_mute = wm9081_digital_mute,
1214 .set_tdm_slot = wm9081_set_tdm_slot, 1212 .set_tdm_slot = wm9081_set_tdm_slot,
@@ -1324,11 +1322,15 @@ static struct snd_soc_codec_driver soc_codec_dev_wm9081 = {
1324 .remove = wm9081_remove, 1322 .remove = wm9081_remove,
1325 .suspend = wm9081_suspend, 1323 .suspend = wm9081_suspend,
1326 .resume = wm9081_resume, 1324 .resume = wm9081_resume,
1325
1326 .set_sysclk = wm9081_set_sysclk,
1327 .set_bias_level = wm9081_set_bias_level, 1327 .set_bias_level = wm9081_set_bias_level,
1328
1328 .reg_cache_size = ARRAY_SIZE(wm9081_reg_defaults), 1329 .reg_cache_size = ARRAY_SIZE(wm9081_reg_defaults),
1329 .reg_word_size = sizeof(u16), 1330 .reg_word_size = sizeof(u16),
1330 .reg_cache_default = wm9081_reg_defaults, 1331 .reg_cache_default = wm9081_reg_defaults,
1331 .volatile_register = wm9081_volatile_register, 1332 .volatile_register = wm9081_volatile_register,
1333
1332 .dapm_widgets = wm9081_dapm_widgets, 1334 .dapm_widgets = wm9081_dapm_widgets,
1333 .num_dapm_widgets = ARRAY_SIZE(wm9081_dapm_widgets), 1335 .num_dapm_widgets = ARRAY_SIZE(wm9081_dapm_widgets),
1334 .dapm_routes = wm9081_audio_paths, 1336 .dapm_routes = wm9081_audio_paths,