浏览代码

ASoC: littlemill: Add userspace control of the WM1250 I/O

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown 13 年之前
父节点
当前提交
31a2239a5a
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      sound/soc/samsung/littlemill.c

+ 7 - 0
sound/soc/samsung/littlemill.c

@@ -211,6 +211,11 @@ static int bbclk_ev(struct snd_soc_dapm_widget *w,
 	return 0;
 	return 0;
 }
 }
 
 
+static const struct snd_kcontrol_new controls[] = {
+	SOC_DAPM_PIN_SWITCH("WM1250 Input"),
+	SOC_DAPM_PIN_SWITCH("WM1250 Output"),
+};
+
 static struct snd_soc_dapm_widget widgets[] = {
 static struct snd_soc_dapm_widget widgets[] = {
 	SND_SOC_DAPM_HP("Headphone", NULL),
 	SND_SOC_DAPM_HP("Headphone", NULL),
 
 
@@ -282,6 +287,8 @@ static struct snd_soc_card littlemill = {
 	.set_bias_level = littlemill_set_bias_level,
 	.set_bias_level = littlemill_set_bias_level,
 	.set_bias_level_post = littlemill_set_bias_level_post,
 	.set_bias_level_post = littlemill_set_bias_level_post,
 
 
+	.controls = controls,
+	.num_controls = ARRAY_SIZE(controls),
 	.dapm_widgets = widgets,
 	.dapm_widgets = widgets,
 	.num_dapm_widgets = ARRAY_SIZE(widgets),
 	.num_dapm_widgets = ARRAY_SIZE(widgets),
 	.dapm_routes = audio_paths,
 	.dapm_routes = audio_paths,