diff options
author | Kirill Marinushkin <kmarinushkin@birdec.tech> | 2018-12-07 20:02:34 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-12-13 16:31:51 +0100 |
commit | bb9963b850ea9e1ef39f4368eae83a9462f60166 (patch) | |
tree | 5dab26bebf9e3beb4e279e16a47fed831f0258c7 /sound/soc/codecs/pcm3060.c | |
parent | ASoC: xlnx: enable i2s driver build (diff) | |
download | linux-bb9963b850ea9e1ef39f4368eae83a9462f60166.tar.xz linux-bb9963b850ea9e1ef39f4368eae83a9462f60166.zip |
ASoC: pcm3060: Add powersaving widgets for DAC and ADC
Enable DAC/ADC only when playing/capturing
Signed-off-by: Kirill Marinushkin <kmarinushkin@birdec.tech>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/pcm3060.c')
-rw-r--r-- | sound/soc/codecs/pcm3060.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/sound/soc/codecs/pcm3060.c b/sound/soc/codecs/pcm3060.c index 1dd851a7b43b..6714aa8d9026 100644 --- a/sound/soc/codecs/pcm3060.c +++ b/sound/soc/codecs/pcm3060.c @@ -198,19 +198,25 @@ static const struct snd_kcontrol_new pcm3060_dapm_controls[] = { }; static const struct snd_soc_dapm_widget pcm3060_dapm_widgets[] = { + SND_SOC_DAPM_DAC("DAC", "Playback", PCM3060_REG64, + PCM3060_REG_SHIFT_DAPSV, 1), + SND_SOC_DAPM_OUTPUT("OUTL"), SND_SOC_DAPM_OUTPUT("OUTR"), SND_SOC_DAPM_INPUT("INL"), SND_SOC_DAPM_INPUT("INR"), + + SND_SOC_DAPM_ADC("ADC", "Capture", PCM3060_REG64, + PCM3060_REG_SHIFT_ADPSV, 1), }; static const struct snd_soc_dapm_route pcm3060_dapm_map[] = { - { "OUTL", NULL, "Playback" }, - { "OUTR", NULL, "Playback" }, + { "OUTL", NULL, "DAC" }, + { "OUTR", NULL, "DAC" }, - { "Capture", NULL, "INL" }, - { "Capture", NULL, "INR" }, + { "ADC", NULL, "INL" }, + { "ADC", NULL, "INR" }, }; /* soc component */ |