summaryrefslogtreecommitdiff
path: root/sound/soc
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-08-25 16:17:42 (GMT)
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-08-25 20:23:37 (GMT)
commit1470bfacb675ab0e25c30c97772a764ca16e0e52 (patch)
tree1752993b0cddc8e272f361b5a98a95d8b0e5aefc /sound/soc
parent6df3198635e2ad961952566a05994bc592abe774 (diff)
downloadlinux-1470bfacb675ab0e25c30c97772a764ca16e0e52.tar.xz
ASoC: wm0010: Add dummy widget for CLKIN
Make it easier to integrate the management of the clock supplying the WM0010 with DAPM by providing a dummy supply widget which supplies the interface widgets, this can be connected to clock outputs by the machines. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc')
-rw-r--r--sound/soc/codecs/wm0010.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm0010.c b/sound/soc/codecs/wm0010.c
index f820b57..b6f7097 100644
--- a/sound/soc/codecs/wm0010.c
+++ b/sound/soc/codecs/wm0010.c
@@ -118,9 +118,18 @@ struct wm0010_spi_msg {
size_t len;
};
+static const struct snd_soc_dapm_widget wm0010_dapm_widgets[] = {
+SND_SOC_DAPM_SUPPLY("CLKIN", SND_SOC_NOPM, 0, 0, NULL, 0),
+};
+
static const struct snd_soc_dapm_route wm0010_dapm_routes[] = {
{ "SDI2 Capture", NULL, "SDI1 Playback" },
{ "SDI1 Capture", NULL, "SDI2 Playback" },
+
+ { "SDI1 Capture", NULL, "CLKIN" },
+ { "SDI2 Capture", NULL, "CLKIN" },
+ { "SDI1 Playback", NULL, "CLKIN" },
+ { "SDI2 Playback", NULL, "CLKIN" },
};
static const char *wm0010_state_to_str(enum wm0010_state state)
@@ -718,6 +727,8 @@ static struct snd_soc_codec_driver soc_codec_dev_wm0010 = {
.set_bias_level = wm0010_set_bias_level,
.set_sysclk = wm0010_set_sysclk,
+ .dapm_widgets = wm0010_dapm_widgets,
+ .num_dapm_widgets = ARRAY_SIZE(wm0010_dapm_widgets),
.dapm_routes = wm0010_dapm_routes,
.num_dapm_routes = ARRAY_SIZE(wm0010_dapm_routes),
};