ASoC: Add VMID widget for wm_hubs devices
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Fri, 15 Jul 2011 06:12:31 +0000 (15:12 +0900)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 14 Aug 2011 04:44:14 +0000 (13:44 +0900)
Currently this does not actually do anything, it is being introduced in
order to facilitate additional power optimisations for current generation
devices.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
sound/soc/codecs/wm8993.c
sound/soc/codecs/wm8994.c
sound/soc/codecs/wm_hubs.c

index f014e5676d20dd6e5f12a5b6024fc0b9710df820..eec8e143511665a538c6950a4f679ad217aad827 100644 (file)
@@ -847,6 +847,7 @@ SND_SOC_DAPM_SUPPLY("CLK_SYS", WM8993_BUS_CONTROL_1, 1, 0, clk_sys_event,
                    SND_SOC_DAPM_PRE_PMU | SND_SOC_DAPM_POST_PMD),
 SND_SOC_DAPM_SUPPLY("TOCLK", WM8993_CLOCKING_1, 14, 0, NULL, 0),
 SND_SOC_DAPM_SUPPLY("CLK_DSP", WM8993_CLOCKING_3, 0, 0, NULL, 0),
+SND_SOC_DAPM_SUPPLY("VMID", SND_SOC_NOPM, 0, 0, NULL, 0),
 
 SND_SOC_DAPM_ADC("ADCL", NULL, WM8993_POWER_MANAGEMENT_2, 1, 0),
 SND_SOC_DAPM_ADC("ADCR", NULL, WM8993_POWER_MANAGEMENT_2, 0, 0),
@@ -880,6 +881,9 @@ SND_SOC_DAPM_PGA("Direct Voice", SND_SOC_NOPM, 0, 0, NULL, 0),
 };
 
 static const struct snd_soc_dapm_route routes[] = {
+       { "MICBIAS1", NULL, "VMID" },
+       { "MICBIAS2", NULL, "VMID" },
+
        { "ADCL", NULL, "CLK_SYS" },
        { "ADCL", NULL, "CLK_DSP" },
        { "ADCR", NULL, "CLK_SYS" },
index 4487c5e6ad8927e3d289cc3c6ccc682e34f23f32..f57e01344adb1dd6bc4cede5a5bf2407327d3d43 100644 (file)
@@ -1209,6 +1209,7 @@ SND_SOC_DAPM_INPUT("Clock"),
 
 SND_SOC_DAPM_SUPPLY_S("MICBIAS Supply", 1, SND_SOC_NOPM, 0, 0, micbias_ev,
                      SND_SOC_DAPM_PRE_PMU),
+SND_SOC_DAPM_SUPPLY("VMID", SND_SOC_NOPM, 0, 0, NULL, 0),
 
 SND_SOC_DAPM_SUPPLY("CLK_SYS", SND_SOC_NOPM, 0, 0, clk_sys_event,
                    SND_SOC_DAPM_POST_PMU | SND_SOC_DAPM_PRE_PMD),
@@ -1526,6 +1527,8 @@ static const struct snd_soc_dapm_route wm8994_revd_intercon[] = {
 static const struct snd_soc_dapm_route wm8994_intercon[] = {
        { "AIF2DACL", NULL, "AIF2DAC Mux" },
        { "AIF2DACR", NULL, "AIF2DAC Mux" },
+       { "MICBIAS1", NULL, "VMID" },
+       { "MICBIAS2", NULL, "VMID" },
 };
 
 static const struct snd_soc_dapm_route wm8958_intercon[] = {
index 017522e7cef9a40673deca7084989f04aeef7f30..ca8ce03510f4ee460da84d12596c6f54ca1e5522 100644 (file)
@@ -711,6 +711,11 @@ static const struct snd_soc_dapm_route analogue_routes[] = {
        { "IN1L PGA", "IN1LP Switch", "IN1LP" },
        { "IN1L PGA", "IN1LN Switch", "IN1LN" },
 
+       { "IN1L PGA", NULL, "VMID" },
+       { "IN1R PGA", NULL, "VMID" },
+       { "IN2L PGA", NULL, "VMID" },
+       { "IN2R PGA", NULL, "VMID" },
+
        { "IN1R PGA", "IN1RP Switch", "IN1RP" },
        { "IN1R PGA", "IN1RN Switch", "IN1RN" },
 
@@ -728,12 +733,14 @@ static const struct snd_soc_dapm_route analogue_routes[] = {
        { "MIXINL", NULL, "Direct Voice" },
        { "MIXINL", NULL, "IN1LP" },
        { "MIXINL", NULL, "Left Output Mixer" },
+       { "MIXINL", NULL, "VMID" },
 
        { "MIXINR", "IN1R Switch", "IN1R PGA" },
        { "MIXINR", "IN2R Switch", "IN2R PGA" },
        { "MIXINR", NULL, "Direct Voice" },
        { "MIXINR", NULL, "IN1RP" },
        { "MIXINR", NULL, "Right Output Mixer" },
+       { "MIXINR", NULL, "VMID" },
 
        { "ADCL", NULL, "MIXINL" },
        { "ADCR", NULL, "MIXINR" },
@@ -764,6 +771,7 @@ static const struct snd_soc_dapm_route analogue_routes[] = {
        { "Earpiece Mixer", "Left Output Switch", "Left Output PGA" },
        { "Earpiece Mixer", "Right Output Switch", "Right Output PGA" },
 
+       { "Earpiece Driver", NULL, "VMID" },
        { "Earpiece Driver", NULL, "Earpiece Mixer" },
        { "HPOUT2N", NULL, "Earpiece Driver" },
        { "HPOUT2P", NULL, "Earpiece Driver" },
@@ -786,9 +794,11 @@ static const struct snd_soc_dapm_route analogue_routes[] = {
        { "SPKR Boost", "SPKR Switch", "SPKR" },
        { "SPKR Boost", "SPKL Switch", "SPKL" },
 
+       { "SPKL Driver", NULL, "VMID" },
        { "SPKL Driver", NULL, "SPKL Boost" },
        { "SPKL Driver", NULL, "CLK_SYS" },
 
+       { "SPKR Driver", NULL, "VMID" },
        { "SPKR Driver", NULL, "SPKR Boost" },
        { "SPKR Driver", NULL, "CLK_SYS" },
 
@@ -802,12 +812,18 @@ static const struct snd_soc_dapm_route analogue_routes[] = {
 
        { "Headphone PGA", NULL, "Left Headphone Mux" },
        { "Headphone PGA", NULL, "Right Headphone Mux" },
+       { "Headphone PGA", NULL, "VMID" },
        { "Headphone PGA", NULL, "CLK_SYS" },
        { "Headphone PGA", NULL, "Headphone Supply" },
 
        { "HPOUT1L", NULL, "Headphone PGA" },
        { "HPOUT1R", NULL, "Headphone PGA" },
 
+       { "LINEOUT1N Driver", NULL, "VMID" },
+       { "LINEOUT1P Driver", NULL, "VMID" },
+       { "LINEOUT2N Driver", NULL, "VMID" },
+       { "LINEOUT2P Driver", NULL, "VMID" },
+
        { "LINEOUT1N", NULL, "LINEOUT1N Driver" },
        { "LINEOUT1P", NULL, "LINEOUT1P Driver" },
        { "LINEOUT2N", NULL, "LINEOUT2N Driver" },